public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [committed] Fix PR target/44705: Invalid MEM with LABEL_REF
@ 2010-07-03 20:53 John David Anglin
  0 siblings, 0 replies; only message in thread
From: John David Anglin @ 2010-07-03 20:53 UTC (permalink / raw)
  To: gcc-patches

The enclosed change fixes PR target/44705.  This regression was exposed
by the new testcase gcc.dg/pr44674.c.  It's a bit surprising that this
was never reported before since the mistake in GO_IF_LEGITIMATE_ADDRESS
has been around for some time.

Tested on hppa2.0w-hp-hpux11.11, hppa64-hp-hpux11.11, hppa-unknown-linux-gnu.
The hpux tests were done on trunk, 4.5 and 4.3.  Committed to trunk, 4.5,
4.4 and 4.3.

Dave
-- 
J. David Anglin                                  dave.anglin@nrc-cnrc.gc.ca
National Research Council of Canada              (613) 990-0752 (FAX: 952-6602)

2010-07-03  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>

	PR target/44705
	* config/pa/pa.h (GO_IF_LEGITIMATE_ADDRESS): Reject LABEL_REF.

Index: config/pa/pa.h
===================================================================
--- config/pa/pa.h	(revision 161574)
+++ config/pa/pa.h	(working copy)
@@ -1142,9 +1142,7 @@
 	       || ((MODE) != SFmode					\
 		   && (MODE) != DFmode)))				\
     goto ADDR;								\
-  else if (GET_CODE (X) == LABEL_REF					\
-	   || (GET_CODE (X) == CONST_INT				\
-	       && INT_5_BITS (X)))					\
+  else if (GET_CODE (X) == CONST_INT && INT_5_BITS (X))			\
     goto ADDR;								\
   /* Needed for -fPIC */						\
   else if (GET_CODE (X) == LO_SUM					\

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-07-03 20:53 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-03 20:53 [committed] Fix PR target/44705: Invalid MEM with LABEL_REF John David Anglin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).