Less good ;-) results from Rittle's string allocator

Loren James Rittle rittle@latour.rsch.comm.mot.com
Sun Nov 25 10:56:00 GMT 2001


In article <20011128161454.A19072@disaster.jaj.com>,
Phil Edwards <pedwards@disaster.jaj.com> writes:

> On Wed, Nov 28, 2001 at 02:55:04AM -0600, Loren James Rittle wrote:
>> BTW, did you see the
>> comment that, under the current implementation, you can't just change
>> _MAX_BYTES?

> No, I didn't.  Where is it, and I'll go look?

Not a very good comment, but from include/bits/stl_alloc.h :

private:
  enum {_ALIGN = 8};
  enum {_MAX_BYTES = 128};
  enum {_NFREELISTS = 16}; // _MAX_BYTES/_ALIGN

Just be careful if you ever change any one of them or expose the value
to be set by the user.



More information about the Libstdc++ mailing list