[PATCH] x86 Linux watchpoints: Couldn't write debug register: Invalid, argument.
Pedro Alves
palves@redhat.com
Fri Jun 20 17:52:00 GMT 2014
On 06/20/2014 06:45 PM, Tom Tromey wrote:
>>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
>
> Pedro> I _still_ had to touch 3 different places with the same code... I'm
> Pedro> very much looking forward to having all that merged.
>
> Yeah. In the meantime perhaps copying the comments into all 3 copies
> would make it simpler for the eventual merge. I noticed that the
> comments are not in linux-x86-low.c or i386-linux-nat.c.
That's following the existing practice, actually.
amd64-linux-nat.c has:
/* On Linux kernel before 2.6.33 commit
72f674d203cd230426437cdcf7dd6f681dad8b0d
if you enable a breakpoint by the DR_CONTROL bits you need to have
already written the corresponding DR_FIRSTADDR...DR_LASTADDR registers.
Ensure DR_CONTROL gets written as the very last register here. */
while i386-linux-nat.c just has:
/* See amd64_linux_prepare_to_resume for Linux kernel note on
i386_linux_dr_set calls ordering. */
I don't think trying to keep this in sync now would help, and at least
this way we have one place that is master. Gary's recent series showed
how when these comments are duplicated they end up diverging. :-/
--
Pedro Alves
More information about the Gdb-patches
mailing list