Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: "Ulrich Weigand" <uweigand@de.ibm.com>
To: cel@us.ibm.com (Carl E. Love)
Cc: palves@redhat.com (Pedro Alves),
	       Ulrich.Weigand@de.ibm.com (Ulrich Weigand),
	       emachado@linux.vnet.ibm.com (Edjunior Barbosa Machado),
	       gdb-patches@sourceware.org
Subject: Re: [PATCH] Fix for gdb.base/pc-fp.exp.
Date: Tue, 23 Aug 2016 16:30:00 -0000	[thread overview]
Message-ID: <20160823163023.AAA2B5BCB@oc7340732750.ibm.com> (raw)
In-Reply-To: <1471969030.4102.52.camel@us.ibm.com> from "Carl E. Love" at Aug 23, 2016 09:17:10 AM

Carl Love wrote:

> That said, the code "set_gdbarch_deprecated_fp_regnum
> (gdbarch, PPC_R0_REGNUM + 1);" sets up register r1 as the frame pointer.
> Register r1 is no longer used to hold the frame pointer on Power.  By
> removing the fp definition for Power in GDB, it causes GDB to fall back
> to the call get_frame_base_address (frame) which returns the correct value
> depending on the specific senario but most of the time is the DWARF
> canonical frame address.

That's true.  In fact, the one place that really cares about the value
returned via $fp is varobj.c:find_frame_addr_in_frame_chain, since you're
supposed to use the value of $fp to identify a frame for MI routines.
And there we explicitly assume that this value matches the value returned
by get_frame_base_address.

> 2016-08-22  Carl Love  <cel@us.ibm.com>
> 
> 	* rs6000-tdep.c (rs6000_gdbarch_init): Remove deprecated call set_gdbarch_deprecated_fp_regnum()
> 	from Power architecture initialization function.

Please watch the 80-char line length limit, which holds for the ChangeLog
as well.  In fact, the text can be shortened anyway: "deprecated" is
redundant (included in the function name), and likewise is "from Power
architecture initialization function" (you already specified which
function --rs6000_gdbarch_init-- you're modifying).  I'd suggest:

 	* rs6000-tdep.c (rs6000_gdbarch_init): Remove call to
	set_gdbarch_deprecated_fp_regnum.

Patch is OK.

Thanks,
Ulrich

-- 
  Dr. Ulrich Weigand
  GNU/Linux compilers and toolchain
  Ulrich.Weigand@de.ibm.com


  parent reply	other threads:[~2016-08-23 16:30 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-22 21:16 Carl E. Love
2016-08-22 23:17 ` Pedro Alves
2016-08-23 16:17   ` Carl E. Love
2016-08-23 16:26     ` Luis Machado
2016-08-23 17:06       ` Ulrich Weigand
2016-08-23 17:19         ` Luis Machado
2016-08-23 16:30     ` Ulrich Weigand [this message]
2016-08-24 15:15       ` Carl E. Love

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160823163023.AAA2B5BCB@oc7340732750.ibm.com \
    --to=uweigand@de.ibm.com \
    --cc=Ulrich.Weigand@de.ibm.com \
    --cc=cel@us.ibm.com \
    --cc=emachado@linux.vnet.ibm.com \
    --cc=gdb-patches@sourceware.org \
    --cc=palves@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox