From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21013 invoked by alias); 4 Dec 2001 11:09:03 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 20879 invoked from network); 4 Dec 2001 11:08:48 -0000 Received: from unknown (HELO krynn.axis.se) (193.13.178.10) by sources.redhat.com with SMTP; 4 Dec 2001 11:08:48 -0000 Received: from ironmaiden.axis.se (ironmaiden.axis.se [10.13.8.120]) by krynn.axis.se (8.12.1/8.12.1/Debian -2) with ESMTP id fB4B8WCJ021058; Tue, 4 Dec 2001 12:08:32 +0100 Received: from axis.com (localhost [127.0.0.1]) by ironmaiden.axis.se (8.9.3/8.9.3/Debian 8.9.3-21) with ESMTP id MAA06872; Tue, 4 Dec 2001 12:08:31 +0100 X-Authentication-Warning: ironmaiden.axis.se: Host localhost [127.0.0.1] claimed to be axis.com Message-ID: <3C0CAEAF.E568773E@axis.com> Date: Tue, 04 Dec 2001 03:09:00 -0000 From: Orjan Friberg Organization: Axis Communications AB X-Mailer: Mozilla 4.76 [en] (X11; U; Linux 2.2.19 i686) X-Accept-Language: en MIME-Version: 1.0 To: Eli Zaretskii CC: gdb-patches@sources.redhat.com Subject: Re: Hardware watchpoints; dealing with false triggers? References: <3C07B6FE.BBFA048D@axis.com> <5137-Fri30Nov2001203301+0200-eliz@is.elta.co.il> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SW-Source: 2001-12/txt/msg00087.txt.bz2 Eli Zaretskii wrote: > > > Date: Fri, 30 Nov 2001 17:42:38 +0100 > > From: Orjan Friberg > > > > Ok, but say that the actual address is shipped with the register packet > > when the target stops so that gdb in fact knows what address was > > actually read/written. I'm thinking gdb could compare that address with > > the watchpoints, and just send the target on its way if the address is > > outside the watched ranges. > > This can be done. The low-level target end is repsonsible to tell > GDB whether a watchpoint triggered, and at what address. So given > enough information from your target, you could write the low-level > watchpoint code to DTRT. Ah, great. > > And this is the key issue: could the interface to the target-specific > > code be extended to handle the concept of "actual watchpoint address"? > > We already have this: it's called target_stopped_data_address. > breakpoint.c uses this macro to see which watchpoint, if any, > triggered. Also great. Thank you very much for your comments on this, Eli. -- Orjan Friberg Axis Communications AB