From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21680 invoked by alias); 24 Jan 2006 03:43:10 -0000 Received: (qmail 21671 invoked by uid 22791); 24 Jan 2006 03:43:10 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Tue, 24 Jan 2006 03:43:09 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1F1F5E-0001Ei-93; Mon, 23 Jan 2006 22:43:04 -0500 Date: Tue, 24 Jan 2006 03:43:00 -0000 From: Daniel Jacobowitz To: Wu Zhou Cc: Eli Zaretskii , gdb-patches@sources.redhat.com, mark@xs4all.nl, bje@au1.ibm.com, anton@au1.ibm.com, pgilliam@us.ibm.com Subject: Re: [RFC] GDB patches for hw watchpoints - revised Message-ID: <20060124034304.GA4719@nevyn.them.org> Mail-Followup-To: Wu Zhou , Eli Zaretskii , gdb-patches@sources.redhat.com, mark@xs4all.nl, bje@au1.ibm.com, anton@au1.ibm.com, pgilliam@us.ibm.com References: <20060122205641.GF27224@nevyn.them.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.8i X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-01/txt/msg00349.txt.bz2 On Tue, Jan 24, 2006 at 11:40:16AM +0800, Wu Zhou wrote: > p630 is one kind of POWER4 based pSeriese server. It is currently the only > available ppc machine I can get. :-) > > In fact, I am not sure before if the ppc arch has nonsteppable watchpoints > or not. But testing on my p630 box, it did had nonsteppable ones. Now > that an architecture either have or doesn't have nonsteppable watchpoints, > can we get from this test a result that ppc architecture has nonsteppable > watchpoints? > > If so, maybe I can just remove the stupid conditional statement below. > (my original intention is to verify that v->mach equals bfd_mach_ppc_630 :-) Well, it'd be nice to have some architectural reference for this. But it's probably a safe bet to assume that this is generally true for all PowerPC targets, so let's just assume it. > Function to_region_ok_for_hw_watchpoint is not in the current target > vector (I means struct target_ops). Maybe we can add it into > target_ops? There are a few other archs also use this. But they had to > include it in nm-xxx-yyy.h. If not, the only method I can think of is > also include its definition in nm-ppc64-linux.h. So what about the > following patch section? > > int (*to_region_size_ok_for_hw_watchpoint) (int); > + int (*to_region_ok_for_hw_watchpoint) (CORE_ADDR *, int); > void (*to_terminal_init) (void); I would recommend replacing to_region_size_ok_for_hw_watchpoint with to_region_ok_for_hw_watchpoint. You'll have to update the callers, including the non-multi-arch ones, to ignore the first argument; shouldn't be hard? -- Daniel Jacobowitz CodeSourcery