From: Jerry LeVan <jerry.levan@ek...> - 2004-11-07 21:49:21
I am putting finishing touches on my little postgresql
database browser and have been watching via "top" what
happens when I fetch largish tables.
When the program starts it idles at
rsize: 16M vsize 172
Fetching a large table causes values to increase
rsize:398M vsize: 579M
Doing a trival fetch yields
rsize: 397M vsize: 577M
Fetching a different large table give
rsize: 473M vsize: 689M
Doing a trivial fetch gives
rsize: 426M vsize: 641M
The trival queries cause the results from the last
query to be released....
mucking around with a variety of queries don't seem
to change the last set of numbers. (the two large tables
where the largest in the database).
Is it the case that Aqua Tcl/Tk cannot shrink it's
size once the memory has been allocated?
ie Is there anyway to get back to the initial 16M size
From: Jeff Hobbs <jeffh@ActiveState.com> - 2004-11-11 22:48:42
> Is it the case that Aqua Tcl/Tk cannot shrink it's
> size once the memory has been allocated?
Tcl on Mac is compiled with threads enabled. In order to
avoid very poor OS malloc performance with threads (which
many OSes suffer from), Tcl has its own threaded malloc
implementation (contributed by the guys at AOL). This is a
high water mark allocator. It should return large single
blocks of memory (above 32K IIRC), but if you have lots of
small blocks allocated, they are freed back into a pool.
Jeff Hobbs, The Tcl Guy
http://www.ActiveState.com/, a division of Sophos