Re: How to display instructions around the current instuction?

Tavis Ormandy via Gdb <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <[email protected]>
On 2021-01-28, Andreas Schwab <[email protected]> wrote:
> On Jan 28 2021, Peng Yu wrote:
>
>> There could be a syntax to go back a given number of instructions.
>
> How do you know how long each instruction is?
>

I just learned about the x/-5i syntax and had the same question. I
didn't look at the code but it does seem to know where the boundaries
are (e.g. if you start in the middle of an instruction).

I guess it must disassemble forward from a previous known location to
learn all the boundaries first?

Tavis.


-- 
 _o)            $ lynx lock.cmpxchg8b.com
 /\\  _o)  _o)  $ finger [email protected]
_\_V _( ) _( )  @taviso
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.