public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [SPARC] Fix PR target/77324
@ 2016-08-28  8:50 Eric Botcazou
  0 siblings, 0 replies; only message in thread
From: Eric Botcazou @ 2016-08-28  8:50 UTC (permalink / raw)
  To: gcc-patches

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

This is the build failure introduced on SPARC by the recent reload patch, 
which causes the pass to be more strict about what it accepts.

Tested on SPARC/Solaris, applied on the mainline.


2016-08-28  Eric Botcazou  <ebotcazou@adacore.com>

	PR target/77324
	* config/sparc/sparc.c (sparc_legitimate_address_p): Accept special
	HIGH+LO construct during reload.

-- 
Eric Botcazou

[-- Attachment #2: pr77324.diff --]
[-- Type: text/x-patch, Size: 672 bytes --]

Index: config/sparc/sparc.c
===================================================================
--- config/sparc/sparc.c	(revision 239761)
+++ config/sparc/sparc.c	(working copy)
@@ -4039,6 +4039,13 @@ sparc_legitimate_address_p (machine_mode mode, rtx
 	 than the alignment (8) may cause the LO_SUM to overflow.  */
       if (mode == TFmode && TARGET_ARCH32)
 	return 0;
+
+      /* During reload, accept the HIGH+LO_SUM construct generated by
+	 sparc_legitimize_reload_address.  */
+      if (reload_in_progress
+	  && GET_CODE (rs1) == HIGH
+	  && XEXP (rs1, 0) == imm1)
+	return 1;
     }
   else if (GET_CODE (addr) == CONST_INT && SMALL_INT (addr))
     return 1;

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

only message in thread, other threads:[~2016-08-28  8:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-28  8:50 [SPARC] Fix PR target/77324 Eric Botcazou

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).