problem with LEAKS and the stack trace
problem with LEAKS and the stack trace
- Subject: problem with LEAKS and the stack trace
- From: Nathan Smyth <email@hidden>
- Date: Sat, 23 May 2009 18:52:45 +0000 (GMT)
Hi there,
I have a program which leaks a LOT of memory, so I am trying to debug it.
On execution, it spawns a few processes, one of which causes the problem.
I run leaks on the pid and I see that mem is leaking:
i.e. I get output like
c088:Clients blah$ leaks 21182
Process 21182: 3526 nodes malloced for 2602 KB
Process 21182: 25 leaks for 448 total leaked bytes.
Leak: 0x701170 size=32 string '/tmp/.s.PGSQL.5432.lock'
Leak: 0x71d610 size=32 string 'investigation_ended'
Leak: 0x71d960 size=32 string 'under_investigation'
....
The issue is that I can't get to the stack trace to find out where these occur!
I have set the MallocStackLogging environment
variable in the shell, which I know works as
every command gives me
ls(21194) malloc: stack logs deleted from /tmp/stack-logs.21194.ls.9p95Ur
If I use malloc_history I get nothing...
c088:Clients blah$ malloc_history 21182 0x701170088:
blah$
Though if I gdb connect to the process, I can catch the line of code for segfaults, for e.g.
Any ideas of how I can help find the erroneous allocations.
THanks Nafe
PS I TRIED using Instruments.app. I chose the executable and set the relevant parameters which should spawn the processes. But once I click run it just sits there. Doesn't seem to be an option :(
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden