From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20788 invoked by alias); 13 Dec 2011 18:49:51 -0000 Received: (qmail 20778 invoked by uid 22791); 13 Dec 2011 18:49:50 -0000 X-SWARE-Spam-Status: No, hits=-7.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 13 Dec 2011 18:49:33 +0000 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id pBDInUXr017759 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 13 Dec 2011 13:49:30 -0500 Received: from host2.jankratochvil.net (ovpn-116-16.ams2.redhat.com [10.36.116.16]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id pBDInNw6023769 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Tue, 13 Dec 2011 13:49:27 -0500 Date: Tue, 13 Dec 2011 18:57:00 -0000 From: Jan Kratochvil To: Pedro Alves Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] PR threads/10729: x86 hw watchpoints and non-stop mode Message-ID: <20111213184923.GA27244@host2.jankratochvil.net> References: <201112051601.59664.pedro@codesourcery.com> <201112122030.25365.pedro@codesourcery.com> <20111212203409.GA28419@host2.jankratochvil.net> <201112131626.03262.pedro@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201112131626.03262.pedro@codesourcery.com> User-Agent: Mutt/1.5.21 (2010-09-15) 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/msg00416.txt.bz2 On Tue, 13 Dec 2011 17:26:03 +0100, Pedro Alves wrote: > Anything else I should address? I am fine with this patch, thanks. > Since we just branched, I'm a bit less worried about > breaking things on other platforms. :-) + > /* Register a method to call whenever a new thread is attached. */ > void > -linux_nat_set_new_thread (struct target_ops *t, void (*new_thread) (ptid_t)) > +linux_nat_set_new_thread (struct target_ops *t, > + void (*new_thread) (struct lwp_info *)) In such case you should change also all the callers on exotic arches: ./arm-linux-nat.c:1274: linux_nat_set_new_thread (t, arm_linux_new_thread); ./ia64-linux-nat.c:861: linux_nat_set_new_thread (t, ia64_linux_new_thread); ./mips-linux-nat.c:1088: linux_nat_set_new_thread (t, mips_linux_new_thread); ./ppc-linux-nat.c:2530: linux_nat_set_new_thread (t, ppc_linux_new_thread); ./s390-nat.c:698: linux_nat_set_new_thread (t, s390_fix_watch_points); > + done prior to resume. Instead, if threads are running when the > + mirror changes, a temporary and transparent stop on all threads > + is forced so they can get their copy of the debug registers > + updated on re-resume. Now, say, a thread hit a watchpoint before IMO s/re-resume/their resume/ but I do not master the language. Thanks, Jan