Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: PAUL GILLIAM <pgilliam@us.ibm.com>
To: Mark Kettenis <mark.kettenis@xs4all.nl>
Cc: gdb-patches@sourceware.org
Subject: Re: patch: signal trampoline frame cache corruption (repost?)
Date: Fri, 03 Nov 2006 17:58:00 -0000	[thread overview]
Message-ID: <1162576236.3428.17.camel@dufur.beaverton.ibm.com> (raw)
In-Reply-To: <200610312328.k9VNScRC012608@elgar.sibelius.xs4all.nl>

[-- Attachment #1: Type: text/plain, Size: 411 bytes --]

On Wed, 2006-11-01 at 00:28 +0100, Mark Kettenis wrote:
> > . . .
> > Ok to commit?  (This is almost an obvious fix, isn't it?)
> 
> Not as you've posted it, since it doesn't adhere to the GNU coding
> style.  But the idea seems alright to me.
> 
> Mark

Ufda!

Sorry about the formatting.  I fixed that, and included a ChangeLog
entry which I also forgot the first time.

Now is it OK to commit?

-=# Paul #=-

[-- Attachment #2: fix-sigtramp-cache.patch --]
[-- Type: text/x-patch, Size: 1381 bytes --]


2006-11-03  Paul Gilliam <pgilliam@us.ibm.com>
	
	* ppc-linux-tdep.c (ppc_linux_sigtramp_cache):  Only
	deal with the floating point registers if the processor
	has a floating point unit.

Index: ppc-linux-tdep.c
===================================================================
RCS file: /cvs/src/src/gdb/ppc-linux-tdep.c,v
retrieving revision 1.78
diff -a -u -r1.78 ppc-linux-tdep.c
--- ppc-linux-tdep.c	18 Apr 2006 19:20:06 -0000	1.78
+++ ppc-linux-tdep.c	3 Nov 2006 17:45:28 -0000
@@ -916,14 +916,18 @@
   trad_frame_set_reg_addr (this_cache, tdep->ppc_cr_regnum,
 			   gpregs + 38 * tdep->wordsize);
 
-  /* Floating point registers.  */
-  for (i = 0; i < 32; i++)
+  if (ppc_floating_point_unit_p(gdbarch))
     {
-      int regnum = i + FP0_REGNUM;
-      trad_frame_set_reg_addr (this_cache, regnum, fpregs + i * tdep->wordsize);
+      /* Floating point registers.  */
+      for (i = 0; i < 32; i++)
+        {
+          int regnum = i + FP0_REGNUM;
+          trad_frame_set_reg_addr (this_cache, regnum, 
+				   fpregs + i * tdep->wordsize);
+        }
+      trad_frame_set_reg_addr (this_cache, tdep->ppc_fpscr_regnum,
+                               fpregs + 32 * tdep->wordsize);
     }
-  trad_frame_set_reg_addr (this_cache, tdep->ppc_fpscr_regnum,
-			   fpregs + 32 * tdep->wordsize);
   trad_frame_set_id (this_cache, frame_id_build (base, func));
 }
 

  reply	other threads:[~2006-11-03 17:58 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-31 19:41 PAUL GILLIAM
2006-10-31 23:28 ` Mark Kettenis
2006-11-03 17:58   ` PAUL GILLIAM [this message]
2006-11-10 21:22     ` Daniel Jacobowitz
2006-11-13 17:42       ` [commit] signal trampoline frame cache corruption PAUL GILLIAM
2006-11-13 17:46         ` Daniel Jacobowitz
2006-11-13 18:57           ` PAUL GILLIAM
2006-11-13 19:05             ` Daniel Jacobowitz
2006-11-14  1:50               ` PAUL GILLIAM

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=1162576236.3428.17.camel@dufur.beaverton.ibm.com \
    --to=pgilliam@us.ibm.com \
    --cc=gdb-patches@sourceware.org \
    --cc=mark.kettenis@xs4all.nl \
    /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