public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* another reload fix for SH
@ 2001-08-15  7:28 Jan Hubicka
  0 siblings, 0 replies; only message in thread
From: Jan Hubicka @ 2001-08-15  7:28 UTC (permalink / raw)
  To: gcc-patches, rth, patches

Hi,
this patch solves the sh newlib build failure.  As I've bugreported earlier, merge_assigned_reloads
calls reg_overlap_mentioned_for_reload_p with first operand being address reloaded.
The function expects just simple objects (memory, register, constant etc.) and crashes.

Proper fix appears to be to avoid attempts to combine with addresses, as the
code does not appear to be designed for such trick.

I am regtesting/bootstrapping the patch on i386 together with previous fix.

Honza

Wed Aug 15 16:25:28 CEST 2001  Jan Hubicka  <jh@suse.cz>

	* reload1.c (merge_assigned_reloads): Do not attempt to merge addresses.

Index: reload1.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/reload1.c,v
retrieving revision 1.286
diff -c -3 -p -r1.286 reload1.c
*** reload1.c	2001/08/13 15:52:21	1.286
--- reload1.c	2001/08/15 14:24:59
*************** merge_assigned_reloads (insn)
*** 6075,6080 ****
--- 6075,6082 ----
  	    for (j = 0; j < n_reloads; j++)
  	      if (rld[j].in != 0
  		  && rld[j].when_needed != RELOAD_OTHER
+ 		  && rld[j].when_needed != RELOAD_FOR_OUTPUT_ADDRESS
+ 		  && rld[j].when_needed != RELOAD_FOR_INPUT_ADDRESS
  		  && reg_overlap_mentioned_for_reload_p (rld[j].in,
  							 rld[i].in))
  		rld[j].when_needed

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

only message in thread, other threads:[~2001-08-15  7:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-08-15  7:28 another reload fix for SH Jan Hubicka

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