Greg Clayton
ae23ed336b
Checking in fixes that I used to track down a leaking module. The heap module can now search the vm regions with the --vm-regions options to any of the heap functions. This is currently slow and often will time out when run on a large program since our user expression timeout is set to 500000 usec. We need to add an API to LLDB where we can specify the timeout for an expression.
...
llvm-svn: 165437
2012-10-08 22:39:38 +00:00
Greg Clayton
a3606adf90
Don't allow an extra entry to slip into the heap results and also add a better output format
...
llvm-svn: 163675
2012-09-12 02:02:32 +00:00
Greg Clayton
4b963415c2
Added "heap" command to get info on all allocations on the heap. Currently only objective C objects are supported since they are easy to detect.
...
llvm-svn: 163637
2012-09-11 18:10:27 +00:00
Greg Clayton
bded106120
Playing around with "objc_refs" over the weekend and improved it to work on a large ObjC program without running into expression timeouts. Now we get a full list of ObjC classes using a runtime function and then qsort the result. Also added code that can count all instances of each ObjC on the heap and also the total byte sizes for the object allocations.
...
llvm-svn: 163520
2012-09-10 17:22:45 +00:00
Greg Clayton
88344b7133
Don't allocate memory when enumerting stack. We now have fixed size buffers to avoid this issue.
...
llvm-svn: 163441
2012-09-08 01:16:16 +00:00
Greg Clayton
7143f00ae9
Improved "objc_refs" a bit to be able to find all instances of a class'
...
superclasses on top of finding the exact class. The current attempt is still
too slow, but it lays the groundwork.
llvm-svn: 163135
2012-09-04 14:09:21 +00:00
Greg Clayton
c373ca5c74
<rdar://problem/12069589>
...
Fixed an issue where not all text would always be seen when running any of the functions in heap.py in Xcode. Now we put the text directly into the command result object and skip STDIO since we have issues with STDIO right now in python scripts.
Also fixed an issue with the "--stack-history" option where MallocStackLoggingNoCompact was assumed to have to be enabled... It doesn't, just MallocStackLogging.
llvm-svn: 163042
2012-09-01 00:34:35 +00:00
Greg Clayton
774ebdfcd1
Added a new "objc_refs" command that will track down all allocations on the heap that have the "isa" for the objective C class at offset zero. This will need to be improved to deal with KVO classes, but it is a start. It also disallows looking up a pointer value of zero since that would return way too many matches.
...
llvm-svn: 161724
2012-08-11 02:26:26 +00:00
Greg Clayton
e04cfd2180
Added the ability to search through sections for pointer data.
...
llvm-svn: 160083
2012-07-11 22:13:18 +00:00
Greg Clayton
5b889eec4a
Remove dependency on internal header file.
...
llvm-svn: 159283
2012-06-27 19:57:13 +00:00
Greg Clayton
341039faca
More fixes to "malloc_history".
...
llvm-svn: 156605
2012-05-11 02:42:36 +00:00
Greg Clayton
7200ed1b94
"--stack-history" now works if you have MallocStackLogggingNoCompact defined in your app's environment.
...
llvm-svn: 156588
2012-05-10 23:37:52 +00:00
Greg Clayton
370f5fd20a
Fixed a build error.
...
llvm-svn: 156586
2012-05-10 23:20:50 +00:00
Greg Clayton
d9fc53509e
Added the ability to get the stack history for a malloc block. This is a work in progress. Checking this in so I can work on it some more.
...
llvm-svn: 156584
2012-05-10 23:17:28 +00:00
Greg Clayton
d712ef0fd7
Remove the "-x" from the finish-swig-Python-LLDB.sh shell options so it doesn't print out all of the commands when executing the shell script.
...
Cleaned up the lldb.utils.symbolication, lldb.macosx.heap and lldb.macosx.crashlog. The lldb.macosx.heap can now build a dylib for the current triple into a temp directory and use it from there.
llvm-svn: 155577
2012-04-25 18:40:20 +00:00
Greg Clayton
81e9ebf798
Move the source and Makefile into a directory so it will be easier to install.
...
llvm-svn: 155523
2012-04-25 01:25:04 +00:00