[tools] Commit memory debug (et al) tooling
These are some changes I made to debug tooling while tracking down the bugfix in the previous commit. Each `scripts/debug_*_alloc.gdb` script has gdb output a `*_allocs.txt` file, which in turn can be parsed by the `scripts/parse_*_allocs.py` script to find errors.
This commit is contained in:
29
scripts/debug_heap_alloc.gdb
Normal file
29
scripts/debug_heap_alloc.gdb
Normal file
@@ -0,0 +1,29 @@
|
||||
das -enabled off
|
||||
break heap_allocator.cpp:81
|
||||
commands
|
||||
silent
|
||||
printf "+ %016lx %4d\n", block, length
|
||||
continue
|
||||
end
|
||||
break heap_allocator.cpp:86
|
||||
commands
|
||||
silent
|
||||
printf "+ %016lx %4d\n", block, length
|
||||
continue
|
||||
end
|
||||
break heap_allocator.cpp:120
|
||||
commands
|
||||
silent
|
||||
printf "- %016lx\n", p
|
||||
continue
|
||||
end
|
||||
break heap_allocator.cpp:140
|
||||
commands
|
||||
silent
|
||||
printf "> %016lx %4d %4d\n", p, old_length, new_length
|
||||
continue
|
||||
end
|
||||
set logging file heap_allocs.txt
|
||||
set logging overwrite on
|
||||
set logging enabled on
|
||||
continue
|
||||
Reference in New Issue
Block a user