From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20196 invoked by alias); 7 Jul 2004 00:28:37 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 20189 invoked from network); 7 Jul 2004 00:28:35 -0000 Received: from unknown (HELO gizmo07bw.bigpond.com) (144.140.70.42) by sourceware.org with SMTP; 7 Jul 2004 00:28:35 -0000 Received: (qmail 30304 invoked from network); 7 Jul 2004 00:28:33 -0000 Received: from unknown (HELO bwmam01.bigpond.com) (144.135.24.69) by gizmo07bw.bigpond.com with SMTP; 7 Jul 2004 00:28:33 -0000 Received: from cpe-203-51-249-49.qld.bigpond.net.au ([203.51.249.49]) by bwmam01.bigpond.com(MAM REL_3_4_2a 2/36274892) with SMTP id 36274892; Wed, 07 Jul 2004 10:28:33 +1000 Message-ID: <40EB43B0.5070009@neurizon.net> Date: Wed, 07 Jul 2004 00:28:00 -0000 From: Steven Johnson User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.6) Gecko/20040115 MIME-Version: 1.0 To: cerickson@mvista.com CC: Wolfgang Schmieder , gdb@sources.redhat.com Subject: Re: hardware watchpoints for ppc References: <200407041103.55619.wolfgang.schmieder@onlinehome.de> <40EABB0E.7080309@mvista.com> In-Reply-To: <40EABB0E.7080309@mvista.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-07/txt/msg00052.txt.bz2 Cal, The MPC855, being a varient of the MPC860 Family does have hardware watchpoint support. If you debug stub doesnt support it, you are going to have to program the registers up manually. (It can be done, but you will need to trial and error it). I suggest reading the section of the MPC855 Manual (or MPC860 Manual) on the Breakpoint/Watchpoint registers. It is with the stuff on BDM Debugging. I have a custom GDB Stub that uses BDM to debug the target, it supports it, but I dont know anything about commercial stubs or non BDM Stubs support for it. If you are using your own custom stub, or have the code of your stub, you could always implement it. For a once off, I would just manually tweak the SPR registers. [CMPA/B/C/D ICR DER COUNTA/B CMPE/F/G/H LCTRL1/2 and ICTRL] to achieve what you want. In my MPC862 book, it is documented in section 45.5 Development Support Programming Model. All of these should be able to be set from GDB like any other register, if your target is an MPC8XX (and not Generic PowerPC). Steven Cal Erickson wrote: > Wolfgang, > From what I know there are no hardware watchpoints available on the PPC > target boards. You might just try watch which will create a software > watchpoint. These do work on PPC processors. > > Cal > > Wolfgang Schmieder wrote: > >> Hello, >> >> is there anybody who knows how I can set hardware watchpoints on ppc >> boards ? I have a mpc855 board running a multithreaded application. >> It appears that one thread (always the same thread) has a corrupted >> stack (always at the same address). I guess I need to set a hardware >> watchpoint in a remote debugging session to find the piece of code >> which is corrupting the stack. >> >> There is one gdb mailing list thread about "supporting hw break/watch >> for embedded ppc", which makes me think that there is at least a >> patch or workaround available to set hardware watchpoints on a ppc >> board. >> >> Thanks, >> >> Wolfgang >> >> > >