This is the mail archive of the gdb-patches@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: [patch] s390*: watchpoints regression [Re: [obv] s390*: Fix build regression]


On Saturday 17 December 2011 19:15:43, Jan Kratochvil wrote:

> I can confirm it works.
> 
> On x86* it now sets DR_CONTROL to 0 already for the wrapper shell.  When there
> exist watchpoints they are suppressed so it still sets 0 and it works.  But
> I do not think GDB should mess with watchpoint registers already for the
> wrapper shell.

In the loop that runs through the shell, fork-child.c:startup_inferior,
nothing inserts breakpoints/watchpoints.  So nothing ends up
setting lwp->arch_private->debug_registers_changed, and so we should
not be setting DR_CONTROL to 0 for the wrapper shell.  Do you
actually see it happen?

> In the hypothetical case the wrapper shell sets DR registers they get
> inherited now by the inferior.  Not that it needs to be handled but it IMO
> suggests DR_CONTROL should be rather set for the real inferior.
> 
> But I do not see some easy enough way how to delay the DR setting till the new
> inferior so I just verified your code which works.
> 
> OK to check it in this way?

Looks okay to me.

-- 
Pedro Alves


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