JIT backtraces on ARM

28 views
Skip to first unread message

Zaheer Ahmad

unread,
Dec 30, 2010, 2:43:24 AM12/30/10
to v8-users
hi, 
I dont currently get backtraces for the JIT code (js calls) on ARM (gdb 6.6). Is there a work around for the same?

Thanks,
Zaheer

Alexandre Rames

unread,
Dec 30, 2010, 4:59:05 AM12/30/10
to v8-u...@googlegroups.com
Hi Zaheer,

GDB has no symbols for the generated code, so you can't use it it to debug the jit code as you would with usual code. (.ou could still use gdb to disassemble, display memory, or step through the assembly code, but I doubt that's what you want to do.)

However you should find what you need in the shell options:
./shell_g --help | grep trace
I think --trace_calls is what you are looking for.

Cheers,

Alexandre

Alexandre Rames

unread,
Dec 30, 2010, 5:36:08 AM12/30/10
to v8-u...@googlegroups.com
I just read this on the v8-dev list. It might interest you.

http://codereview.chromium.org/5965011/

Alexandre

Zaheer Ahmad

unread,
Dec 30, 2010, 6:03:22 AM12/30/10
to v8-u...@googlegroups.com
On Thu, Dec 30, 2010 at 3:29 PM, Alexandre Rames <alexand...@gmail.com> wrote:
Hi Zaheer,

GDB has no symbols for the generated code, so you can't use it it to debug the jit code as you would with usual code. (.ou could still use gdb to disassemble, display memory, or step through the assembly code, but I doubt that's what you want to do.)
Yeah, i meant the gdb does not show the complete trace on ARM, it stops after the first JIT frame.

Alexandre Rames

unread,
Dec 30, 2010, 6:17:17 AM12/30/10
to v8-u...@googlegroups.com
So did the --trace_calls option solve your problem?

Alexandre

Zaheer Ahmad

unread,
Dec 30, 2010, 6:38:34 AM12/30/10
to v8-u...@googlegroups.com
It doesn't. trace_calls seems related to dumping all the js traces. 
what iam looking for is to get full backtraces on arm similar to x86. Its possible that gdb doesnt understand the js frame layout on arm and hence it fails.

appreciate any pointers.

Thanks,
Zaheer

Alexandre Rames

unread,
Dec 30, 2010, 6:57:43 AM12/30/10
to v8-u...@googlegroups.com
Except maybe with the new commit I copied the link to, you won't be able to have gdb print JS calls information. To backtrace calls gdb needs debug information and specific stack layouts that are not supported for the jit code (in v8 at least). GDB will get lost as soon as you jump from compiled C++ code to generated code (whatever your architecture is).
Reply all
Reply to author
Forward
0 new messages