From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17893 invoked by alias); 9 Nov 2006 04:57:51 -0000 Received: (qmail 17883 invoked by uid 22791); 9 Nov 2006 04:57:50 -0000 X-Spam-Check-By: sourceware.org Received: from nile.gnat.com (HELO nile.gnat.com) (205.232.38.5) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 09 Nov 2006 04:57:45 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-nile.gnat.com (Postfix) with ESMTP id 7FE1748CE29 for ; Wed, 8 Nov 2006 23:57:43 -0500 (EST) Received: from nile.gnat.com ([127.0.0.1]) by localhost (nile.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 05195-01-8 for ; Wed, 8 Nov 2006 23:57:43 -0500 (EST) Received: from takamaka.act-europe.fr (unknown [70.71.0.212]) by nile.gnat.com (Postfix) with ESMTP id 2961748CE10 for ; Wed, 8 Nov 2006 23:57:43 -0500 (EST) Received: by takamaka.act-europe.fr (Postfix, from userid 1000) id 1DB0134C099; Wed, 8 Nov 2006 23:58:01 -0500 (EST) Date: Thu, 09 Nov 2006 04:57:00 -0000 From: Joel Brobecker To: gdb-patches@sources.redhat.com Subject: [RFA/sparc] Fix step-bt.exp: backtrace after second instruction step Message-ID: <20061109045801.GK3582@adacore.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="45Z9DzgjV8m4Oswq" Content-Disposition: inline User-Agent: Mutt/1.4.2.2i 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-11/txt/msg00046.txt.bz2 --45Z9DzgjV8m4Oswq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-length: 509 Hello, I encountered on sparc the same problem I saw on i386: When scanning a function prologue, if an instruction is replaced by a breakpoint, we read the breakpoint instead of reading the original instruction. Fixed using the same method as in i386... 2006-11-08 Joel Brobecker * sparc-tdep.c (sparc_fetch_instruction): Read instruction using read_memory_nobpt. Tested on sparc-solaris, no regression, and fixes one FAIL in step-bt.exp. OK to apply? -- Joel --45Z9DzgjV8m4Oswq Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="sparc-tdep.c.diff" Content-length: 544 Index: sparc-tdep.c =================================================================== RCS file: /cvs/src/src/gdb/sparc-tdep.c,v retrieving revision 1.173 diff -u -p -r1.173 sparc-tdep.c --- sparc-tdep.c 12 Jul 2006 18:13:45 -0000 1.173 +++ sparc-tdep.c 9 Nov 2006 04:54:05 -0000 @@ -99,7 +99,7 @@ sparc_fetch_instruction (CORE_ADDR pc) int i; /* If we can't read the instruction at PC, return zero. */ - if (target_read_memory (pc, buf, sizeof (buf))) + if (read_memory_nobpt (pc, buf, sizeof (buf))) return 0; insn = 0; --45Z9DzgjV8m4Oswq--