Skip to content
Joran Siu edited this page Apr 3, 2014 · 6 revisions

This project consists of some tools to enhance the debugging experience of V8z (https://github.com/andrewlow/v8z). Here are some examples on using the tools:

which_stub_from_addr.pl

Given an address, the script tries to determine the name of the corresponding stub and the offset into that stub.

Usage:

which_stub_from_addr.pl 0xADDRESS print_stubs.txt

where 0xADDRESS is the address to search, and print_stubs.txt is generated by:

d8 --print_code_stubs --print_all_code > print_stubs.txt

If you are running under GDB, and hardcode the location of print_stubs.txt output, you can set up a GDB macro definition as such:

define whered8
  shell perl ../v8z-devtools/which_stub_from_addr.pl $arg0 print_stubs.txt
end
document whered8
Prints the stub name and offset of given addr.
end

During a live debugging session, you can then query at a failing offset:

(gdb) whered8 0x32e0a37a
0x32e0a37a - <CEntryStub+122>
Clone this wiki locally