[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Tracking memory leaks -- advice needed
From: iglio () fub ! it (Pietro Iglio)
Date: 1999-06-20 8:37:47
[Download RAW message or body]
I'm tracking memory usage in kpanel and I need a feature that
--AFAIK-- is not
provided by tools such as ccmalloc and leaktracker.
I need a way to detect how much memory has been allocated between two
execution
points. Suppose, for example, that I'm going through the execution
with gdb and
I have the following example code:
Foo* foo = new Foo(.....);
fee = buildFeeTree(....);
I would like to call a function (eg.) get_allocated_memory() from gdb
before
and after every step to know how many bytes have been allocated by the
constructor
of Foo and during the execution of buildFeeTree().
I have tried to use the __malloc_hook, __realloc_hook and __free_hook
of the
glibc library, but somewhere in the runtime the __malloc_hook is reset
to NULL.
Any help, please?
Thanks,
-- Pietro
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic