|
|
||
|
Is it safe to trigger EGC by returning 0 once from allocation function?Sure, as long as the call is actually trying to allocate memory (that is, newsize > oldsize). The allocation function should never fail when freeing memory (newsize <= oldsize).
Thanks!
Just tried, and it really works. With my generational gc test code,
maximum collectgarbage("count") value is actually _higher_ (also
the TRACEMEM shows higher value), even though the resident set size,
reported by time -v is lower.
What exactly does the value of collectgarbage("count") mean?