Re: sdirno/sfileno sizes

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Fri, 30 Mar 2001 11:09:25 +0200

Andres Kroonmaa wrote:

> I decided to sort chunks in ram based on pointer value, so that all mem
> used tends to compact the heap over time. Always pick chunk closest to
> heap start. Idle chunks are released if not touched for some time, or
> if over memory_pools_limit. Chunk size is variable depending on item
> size.

How large chunks are you using?

At least for Linux malloc() you might want to change this criteria for
the larger pools. Any allocations of 128KB or more is done outside the
heap, making sorting on address irrelevant. Can be tuned to use a lower
limit, or done manually using mmap() to allocate the chunks.

/Henrik
Received on Fri Mar 30 2001 - 02:41:06 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:13:41 MST