Forum .LRN Q&A: Re: Re: memory usage

Collapse
4: Re: Re: memory usage (response to 3)
Posted by Malte Sussdorff on
How did you disable the memory allocator? What are the side effects?
Collapse
5: Re: Re: Re: memory usage (response to 4)
Posted by Daniël Mantione on
The configure script sets a define to enable the thread memory allocator if you enable threads. I disabled it by hacking the configure script:

# USE_THREAD_ALLOC tells us to try the special thread-based
# allocator that significantly reduces lock contention
# AC_DEFINE(USE_THREAD_ALLOC)

(There is now a # in front.)

If you do this TCL will use its normal memory manager, which is completely thread safe. I notice no performance difference, allthough my site has rather low traffic. It saves a lot of memory.