From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9568 invoked by alias); 3 Sep 2002 22:40:32 -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 9557 invoked from network); 3 Sep 2002 22:40:32 -0000 Received: from unknown (HELO dr-evil.shagadelic.org) (208.176.2.174) by sources.redhat.com with SMTP; 3 Sep 2002 22:40:32 -0000 Received: by dr-evil.shagadelic.org (Postfix, from userid 7518) id 63F939869; Tue, 3 Sep 2002 15:40:31 -0700 (PDT) Date: Tue, 03 Sep 2002 15:40:00 -0000 From: Jason R Thorpe To: Richard.Earnshaw@arm.com Cc: gdb-patches@sources.redhat.com Subject: Re: [PATCH/RFA] arm-netbsdelf cross-debugging fixes Message-ID: <20020903154031.U12843@dr-evil.shagadelic.org> Mail-Followup-To: Jason R Thorpe , Richard.Earnshaw@arm.com, gdb-patches@sources.redhat.com References: <20020901165843.B4034@dr-evil.shagadelic.org> <200209031923.g83JN2109855@pc960.cambridge.arm.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="bg08WKrSYDhXBjb5" Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <200209031923.g83JN2109855@pc960.cambridge.arm.com>; from rearnsha@cambridge.arm.com on Tue, Sep 03, 2002 at 08:23:01PM +0100 Organization: Wasabi Systems, Inc. X-SW-Source: 2002-09/txt/msg00048.txt.bz2 --bg08WKrSYDhXBjb5 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-length: 666 On Tue, Sep 03, 2002 at 08:23:01PM +0100, Richard Earnshaw wrote: > > While there, I also fixed a problem with arm_addr_bits_remove -- No > > 26-bit systems can run in Thumb mode, and so doing an arm_pc_is_thumb > > on them is unnecessary (and could return incorrect results if debugging > > code which runs in FIQ mode, since (pc & 1) == FIQ mode on those CPUs). > > > Yep, that would be a good move, but it would be easier to say yes if it > were a separate patch. Ok, here's this one, separated out. * arm-tdep.c (arm_addr_bits_remove): Don't check for Thumb mode if arm_apcs_32 is false. -- -- Jason R. Thorpe --bg08WKrSYDhXBjb5 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=arm-addr-bits-patch Content-length: 892 Index: arm-tdep.c =================================================================== RCS file: /cvs/src/src/gdb/arm-tdep.c,v retrieving revision 1.69 diff -c -r1.69 arm-tdep.c *** arm-tdep.c 24 Aug 2002 00:21:34 -0000 1.69 --- arm-tdep.c 3 Sep 2002 22:29:17 -0000 *************** *** 225,234 **** static CORE_ADDR arm_addr_bits_remove (CORE_ADDR val) { ! if (arm_pc_is_thumb (val)) ! return (val & (arm_apcs_32 ? 0xfffffffe : 0x03fffffe)); else ! return (val & (arm_apcs_32 ? 0xfffffffc : 0x03fffffc)); } /* When reading symbols, we need to zap the low bit of the address, --- 225,234 ---- static CORE_ADDR arm_addr_bits_remove (CORE_ADDR val) { ! if (arm_apcs_32) ! return (val & (arm_pc_is_thumb (val) ? 0xfffffffe : 0xfffffffc)); else ! return (val & 0x03fffffc); } /* When reading symbols, we need to zap the low bit of the address, --bg08WKrSYDhXBjb5--