|
From: Helge H. <hel...@sk...> - 2001-08-20 09:50:47
|
"Sven C. Koehler" wrote:
> Concerning Boehm GC, I am somewhat suspicious regarding conservative GC,
> since it doesn't use typed memory, and so it might not see all leaks that
> are there--but I did not read yet much in the documentation of Boehm GC.
> Another thing is that it seems to require a rebuilt of libobjc, what is
> expensive.
As long as ObjC objects are concerned Boehm GC *does* use typed memory
and is exact ! It only needs to guess on stack and global variables.
While it may not find all leaks it will find 99.99% of the leaks.
> One could read the return address from the stack, and translate it
> afterwards via binutils's addr2line program, but that's very evil!
More important: it's very slow which makes it unusable. You can get the
callee information in the RETAIN macros, but even then tracking all RC
owners will be a huge memory problem !
#define RETAIN(x) \
[x retainFromFunction:__PRETTY_FUNCTION__ \
file:__FILE__ line:__LINE__];
Greetings
Helge
--
SKYRIX Software AG - http://www.skyrix.com
Web Application Technology for Enterprises
|