This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

another reload fix for SH

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.


Wed Aug 15 16:25:28 CEST 2001  Jan Hubicka  <>

	* 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,

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]