This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: question about ARM watchpoints


Hi

On Mon, Sep 1, 2014 at 8:57 PM, Joel Brobecker <brobecker@adacore.com> wrote:
> Everything works pretty well, except that we noticed that GDB stops
> 2 instructions after the variable update, rather than at the next
> instruction.

I get the same behaviour on the Black Magic Probe on ARMv7-M.
The DWT halts the core on the instruction after the address match.

> The question then becomes: Is QEMU behaving correctly, in which
> case we should be modifying GDB, or is QEMU signaling GDB too
> late, in which case we should be fixing QEMU?

What QEMU is doing is the same as the hardware DWT block, so I'd
say this is the correct behaviour.  The fix should be in GDB.  Working
around this in QEMU would leave all hardware based implementations
broken.

Regards,
Gareth

-- 
Black Sphere Technologies Ltd.

Web: www.blacksphere.co.nz
Mobile: +64 27 777 2182
Tel: +64 9 478 8885
Skype: gareth.mcmullin
LinkedIn: http://nz.linkedin.com/in/gsmcmullin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]