This is the mail archive of the 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: [RFA/commit] arm-tdep.c: Do not single-step after hitting a watchpoint.

On 09/29/2014 06:51 PM, Joel Brobecker wrote:
> Hello all,
>> Hmm.  So when the data abort triggers at fault+8, the instruction
>> that triggered the abort hasn't actually completed, right?  No memory
>> has changed yet.
>> So if nothing does the adjustment, like Gareth found out happens with
>> the Black Magic Probe, then we'll resume execution from the
>> wrong address/instruction (with the effects of the skipped instructions
>> missing, including the memory write...).  Did I understand that
>> right?  (Gareth, is that what you see?)
> I have been trying to understand the various contributions, and
> I admit I am still not quite sure...
> Does it look like the patch I proposed is correct? It seems to be
> supported by Terry Guo's experiments as well...

Nope, Terry's experiments supported the current code.

The experiments (which were on Linux) showed that the watchpoint was
reported to GDB first with the PC pointing at the instruction that
accessed memory, and then GDB single-stepped once, and the PC ends up
pointing at one instruction after the instruction that changed memory.

Pedro Alves

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