Re: Disassemble arbitrary memory with disas?

Andreas Schwab
2009-05-22T21:54:22Z

Toshi Morita <tm314159@yahoo.com> writes:

> I'm currently debugging a JIT which dynamically generates code, and I'd like to disassemble it with the "disas" command in GDB.
>
> However, since there isn't any symbolic information for the buffer in which the code is generated, GDB refuses to disassemble.
>
> Is there a way to do this?

(gdb) help disass
Disassemble a specified section of memory.
Default is the function surrounding the pc of the selected frame.
With a /m modifier, source lines are included (if available).
With a single argument, the function surrounding that address is dumped.
Two arguments are taken as a range of memory to dump.

Andreas.

--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."