Improvement of memory allocation possible?

2006-05-11 Thread Joerg Maschtaler
Hi, if it possible to add an option which allows to shrink memory buffers immediatly if they are not full? [1] I run an Tor server on a virtual server in which the amount of RAM is the bottleneck of this system. Since ~ 3 weeks i measure the resident memory allocation and the corresponding

Re: Improvement of memory allocation possible?

2006-05-11 Thread Nick Mathewson
On Thu, May 11, 2006 at 09:21:05PM +0200, Joerg Maschtaler wrote: Hi, if it possible to add an option which allows to shrink memory buffers immediatly if they are not full? [1] I don't think you would want that; the CPU usage would be *insanely* high. Every time you transmitted any

Re: Improvement of memory allocation possible?

2006-05-11 Thread Ben Wilhelm
Does your allocator actually return memory to the OS? Many don't, and in my (admittedly brief) look through the source, I don't remember seeing a custom allocator. If it doesn't return memory to the OS, it'll just sit at its maximum allocated size for all eternity, despite not using much of

Re: Improvement of memory allocation possible?

2006-05-11 Thread Watson Ladd
The default system one should if large blocks are allocated and deallocated at once.On 5/11/06, Ben Wilhelm [EMAIL PROTECTED] wrote:Does your allocator actually return memory to the OS? Many don't, and in my (admittedly brief) look through the source, I don't remember seeing acustom allocator.If