From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20631 invoked by alias); 17 Dec 2011 19:40:36 -0000 Received: (qmail 20622 invoked by uid 22791); 17 Dec 2011 19:40:35 -0000 X-SWARE-Spam-Status: No, hits=2.1 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,SARE_RECV_IP_082154 X-Spam-Check-By: sourceware.org Received: from mail-iy0-f169.google.com (HELO mail-iy0-f169.google.com) (209.85.210.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sat, 17 Dec 2011 19:40:22 +0000 Received: by iacb35 with SMTP id b35so5328659iac.0 for ; Sat, 17 Dec 2011 11:40:22 -0800 (PST) Received: by 10.50.188.129 with SMTP id ga1mr16956874igc.69.1324150822073; Sat, 17 Dec 2011 11:40:22 -0800 (PST) Received: from scottsdale.localnet (bl6-167-28.dsl.telepac.pt. [82.155.167.28]) by mx.google.com with ESMTPS id d19sm47532386ibh.8.2011.12.17.11.40.16 (version=SSLv3 cipher=OTHER); Sat, 17 Dec 2011 11:40:17 -0800 (PST) From: Pedro Alves To: Jan Kratochvil Subject: Re: [patch] s390*: watchpoints regression [Re: [obv] s390*: Fix build regression] Date: Sat, 17 Dec 2011 19:44:00 -0000 User-Agent: KMail/1.13.6 (Linux/2.6.38-13-generic; KDE/4.7.2; x86_64; ; ) Cc: gdb-patches@sourceware.org References: <20111217094753.GA20113@host2.jankratochvil.net> <201112171229.27796.pedro@codesourcery.com> <20111217191543.GA5564@host2.jankratochvil.net> In-Reply-To: <20111217191543.GA5564@host2.jankratochvil.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201112171940.13962.alves.ped@gmail.com> X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2011-12/txt/msg00579.txt.bz2 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