This is the mail archive of the gcc-patches@gcc.gnu.org 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]
Other format: [Raw text]

Re: [patch] reload1: detail reload failures in dump file


> More importantly, it seems to me that this should print R, not I.
> Looking at debug_reload_to_stream, reloads seem to be numbered by
> the index in RLD.  In this case the index in RLD is R.

I guess I never had a failure in a resequenced reload set :-P

> OK for mainline with those changes if you agree with them.

Patch as applied...

2005-12-19  DJ Delorie  <dj@redhat.com>

	* reload1.c (spill_failure): Dump reload data to dump file.
	(find_reload_regs): Likewise.

Index: reload1.c
===================================================================
--- reload1.c	(revision 108829)
+++ reload1.c	(working copy)
@@ -1831,6 +1831,8 @@
 	  && rld[r].regno == -1)
 	if (! find_reg (chain, i))
 	  {
+ 	    if (dump_file)
+ 	      fprintf (dump_file, "reload failure for reload %d\n", r);
 	    spill_failure (chain->insn, rld[r].class);
 	    failure = 1;
 	    return;
@@ -1899,6 +1901,12 @@
     {
       error ("unable to find a register to spill in class %qs",
 	     reg_class_names[class]);
+ 
+      if (dump_file)
+ 	{
+ 	  fprintf (dump_file, "\nReloads for insn # %d\n", INSN_UID (insn));
+ 	  debug_reload_to_stream (dump_file);
+ 	}
       fatal_insn ("this is the insn:", insn);
     }
 }


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