]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* reload1.c (merge_assigned_reloads): Don't change reloads
authoramylaar <amylaar@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 17 Jun 2002 11:33:20 +0000 (11:33 +0000)
committeramylaar <amylaar@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 17 Jun 2002 11:33:20 +0000 (11:33 +0000)
other than RELOAD_FOR_INPUT_ADDRESS / RELOAD_FOR_INPADDR_ADDRESS
to RELOAD_OTHER when there are conflicting input reloads.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54703 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/reload1.c

index 0fb38c6c22d793a6daa14e78fec924575c118d27..46433106da057491012e878b507991d214cb2481 100644 (file)
@@ -1,3 +1,9 @@
+Mon Jun 17 12:32:24 2002  J"orn Rennecke <joern.rennecke@superh.com>
+
+       * reload1.c (merge_assigned_reloads): Don't change reloads
+       other than RELOAD_FOR_INPUT_ADDRESS / RELOAD_FOR_INPADDR_ADDRESS
+       to RELOAD_OTHER when there are conflicting input reloads.
+
 2002-06-17  Richard Earnshaw  (rearnsha@arm.com)
 
        * function.c (epilogue_done): Correctly build a sequence of insns for
index 81adb8dcbf8ed7fd00b8d4a289997b68501bef95..1cbdde152aa392714f2e466278f2e16cbc52a075 100644 (file)
@@ -6096,11 +6096,19 @@ merge_assigned_reloads (insn)
             if they were for inputs, RELOAD_OTHER for outputs.  Note that
             this test is equivalent to looking for reloads for this operand
             number.  */
+         /* We must take special care when there are two or more reloads to
+            be merged and a RELOAD_FOR_OUTPUT_ADDRESS reload that loads the
+            same value or a part of it; we must not change its type if there
+            is a conflicting input.  */
 
          if (rld[i].when_needed == RELOAD_OTHER)
            for (j = 0; j < n_reloads; j++)
              if (rld[j].in != 0
                  && rld[j].when_needed != RELOAD_OTHER
+                 && rld[j].when_needed != RELOAD_FOR_OTHER_ADDRESS
+                 && (! conflicting_input
+                     || rld[j].when_needed == RELOAD_FOR_INPUT_ADDRESS
+                     || rld[j].when_needed == RELOAD_FOR_INPADDR_ADDRESS)
                  && reg_overlap_mentioned_for_reload_p (rld[j].in,
                                                         rld[i].in))
                rld[j].when_needed