Page 1 of 1

Does importing of lots of functions costs much?

Posted: Fri Dec 19, 2003 9:53 am
by HPW
When I import lots of functions does this costs much? (memory, cpu-load)

I have set up a loader-file for the pdf-lib with 304 functions.
Can I do this as default or must I pick only the current needed functions?
Or are the functions only some more symbols in the symbol-table?

Posted: Fri Dec 19, 2003 10:56 am
by HPW
After some tests I found only a little difference between 1 and all import-calls. It seems when the DLL is once loaded it doesn't change much. Memory load of the tk-frontend is more changing without a clear reason. But it seems not related to (import ..).

Posted: Fri Dec 19, 2003 1:55 pm
by Lutz
The memory impact of an 'import' is minimal, just another symbol (32 bytes) and a cell to hold is (16 bytes). Calling overhead is very minimal too.

The memory load of the fronted is Tcl/Tk stuff and I don't know much about it. I know that the console window as it accumulates history consumes memory and gets slower. Click the 'clear-console' - button (the white paper sheet) once in a while or do a Ctrl-L.

Lutz