Im trying to debug a memory leak problem. I use mtrace () to get the malloc / free / realloc trace. Ive launched my program and now has a huge log file. So far, so good. But I have problems interpreting the file. Look at these lines:
@ /usr/java/ibm-java2-x86_64-50/jre/bin/libj9prt23.so:[0x2b270a384a34] + 0x1502570 0x68 @ /usr/java/ibm-java2-x86_64-50/jre/bin/libj9prt23.so:[0x2b270a384a34] + 0x1502620 0x30 @ /usr/java/ibm-java2-x86_64-50/jre/bin/libj9prt23.so:[0x2b270a384a34] + 0x2aaab43a1700 0xa80 @ /usr/java/ibm-java2-x86_64-50/jre/bin/libj9prt23.so:[0x2b270a384a34] + 0x1501460 0xa64
It is strange that one call (the same return address) is responsible for 4 distributions.
Even a stranger:
@ /usr/java/ibm-java2-x86_64-50/jre/bin/libj9prt23.so:[0x2b270a384a34] + 0x2aaab43a1700 0xa2c β¦ @ /usr/java/ibm-java2-x86_64-50/jre/bin/libj9prt23.so:[0x2b270a384a34] + 0x2aaab43a1700 0xa80
Between these two lines, the 0x2aaab43a1700 block is never freed.
Does anyone know how to explain this? How can I call the result in 4 distributions? And how can malloc return the previously allocated address?
edit 2008/09/30: a script to analyze the mtrace () output provided by GLIBC (mtrace.pl) will not help here. It will simply say: Alloc 0x2aaab43a1700 duplicate. But how could this happen?
source share