Andre Poenitz <[EMAIL PROTECTED]> writes:

| On Sat, Mar 11, 2006 at 04:28:08PM +0100, Lars Gullik Bjønnes wrote:
| > | >         template<class It>
| > | >         RandomAccessList(It it_start, It it_end) {
| > | 
| > | Maybe adding 'reserve' is in order.
| > 
| > imho leave all optimizations of that kind out for now.
| 
| Given that this is work to improve performance I wonder what
| the reasoning behind leaving out some 'obvious' optimization
| might be...

that it is not as an obvious optimization at all...
Figuring out what to revserve is an O(n) operations in itself. And
most of hte time the vector will alreay be larger or have the correct
size anyway.

-- 
        Lgb

Reply via email to