Re: [hatari-devel] Debugger 'n' command

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Hi,

Vincent, is the patch enough for what you were looking for?

	- Eero

On 04/11/2016 01:55 AM, Eero Tamminen wrote:
Hi,

On 04/11/2016 01:01 AM, Nicolas Pomarède wrote:
Le 10/04/2016 23:40, Eero Tamminen a écrit :

The reason why it's not currently supported, is that branching
can also be forwards.  Then "n" command breakpoint for the next
instruction might never terminate, which IMHO is worse than
lacking support for skipping loops.

Does somebody feel adding support for determining when instruction
at PC is a branch going backwards?  :-)


For bne/beq it would be more complicated, but in the case of dbcc it
will mostly be backward ; dbcc uses 2 words, 1 with the opcode, 1 with
the displacement ; if the the 2nd word is <0, then it will go backward
and a breakpoint after the dbcc will work.

format for DBcc is : 0101 cccc 1100 1rrr  . so if ( opcode & 0x50A8 ) ==
0x50a8, then you have a DBcc and you can check the next word.

Does the attached patch work OK?


     - Eero




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/