From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23263 invoked by alias); 28 Sep 2007 17:57:05 -0000 Received: (qmail 23252 invoked by uid 22791); 28 Sep 2007 17:57:04 -0000 X-Spam-Check-By: sourceware.org Received: from NaN.false.org (HELO nan.false.org) (208.75.86.248) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 28 Sep 2007 17:57:01 +0000 Received: from nan.false.org (localhost [127.0.0.1]) by nan.false.org (Postfix) with ESMTP id 248109832B; Fri, 28 Sep 2007 17:56:59 +0000 (GMT) Received: from caradoc.them.org (22.svnf5.xdsl.nauticom.net [209.195.183.55]) by nan.false.org (Postfix) with ESMTP id B02949831F; Fri, 28 Sep 2007 17:56:58 +0000 (GMT) Received: from drow by caradoc.them.org with local (Exim 4.67) (envelope-from ) id 1IbK5B-0005L4-Ly; Fri, 28 Sep 2007 13:56:57 -0400 Date: Fri, 28 Sep 2007 17:57:00 -0000 From: Daniel Jacobowitz To: "Maciej W. Rozycki" Cc: gdb-patches@sourceware.org, Chris Dearman , "Maciej W. Rozycki" Subject: Re: mips-tdep.c: Fix retrieval of the virtual frame pointer Message-ID: <20070928175657.GA20487@caradoc.them.org> Mail-Followup-To: "Maciej W. Rozycki" , gdb-patches@sourceware.org, Chris Dearman , "Maciej W. Rozycki" References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.15 (2007-04-09) X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2007-09/txt/msg00421.txt.bz2 On Fri, Sep 28, 2007 at 06:46:19PM +0100, Maciej W. Rozycki wrote: > Hello, > > A number of test cases in the gdb.trace/ subset fail with an error like > this: Have I mentioned that I have queued patches I haven't gotten to yet? :-) I spent the past two weeks fighting with an obstinate qemu, and one of the patches I was testing was basically this one. Mine was: +/* Dummy virtual frame pointer method. This is no more or less accurate + than most other architectures; we just need to be explicit about it, + because the pseudo-register gdbarch_sp_regnum will otherwise lead to + an assertion failure. */ + +static void +mips_virtual_frame_pointer (CORE_ADDR pc, int *reg, LONGEST *offset) +{ + *reg = MIPS_SP_REGNUM; + *offset = 0; +} I think this is more accurate than yours, since these: > + if (gdbarch_deprecated_fp_regnum (current_gdbarch) >= 0) > + else if (MIPS_SP_REGNUM >= 0) are both constants for MIPS. -- Daniel Jacobowitz CodeSourcery