[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] Review wanted. Simplifying the IQueryResult/IQuery API

On 2009-12-17 18:26, Pascal Rapicault wrote:

I have not reviewed the patch but I'm not a big fan of the removal of size and toCollection.
They end up being particularly useful in some places, especially to convert from one type to the other, or eventually create collections with the right size up front (which saves a lot of growth when you work on very large collections).

I agree that there are cases where all the IUs can't be held in memory, however there are cases in today's code (engine and planner) where I don't see how not having all the IUs in memory is possible, and where the presence of such methods is necessary.
In the end I think I could probably leave without the toCollection, but loosing size would likely cause performance issues.

I doubt that. I think it's rather the opposite given the number of unnecessary collection copies that were removed.

Is there any way we can compare performance, with and without my patch? Any particular scenarios that you are worried about?

- thomas