]> gcc.gnu.org Git - gcc.git/commitdiff
re PR rtl-optimization/10315 ([powerpc] ICE: in extract_insn, at recog.c:2175)
authorRichard Henderson <rth@redhat.com>
Fri, 25 Apr 2003 17:43:58 +0000 (10:43 -0700)
committerRichard Henderson <rth@gcc.gnu.org>
Fri, 25 Apr 2003 17:43:58 +0000 (10:43 -0700)
        PR opt/10315
        * config/rs6000/rs6000.c (rs6000_emit_move): Only elide proper
        checks during reload; use validize_mem instead of adjust_address.

From-SVN: r66071

gcc/ChangeLog
gcc/config/rs6000/rs6000.c

index 7d291ea971b94f173c551e69b0d207743d434cc7..2c378a824be3310bbdbf14b74579e83531926708 100644 (file)
@@ -1,3 +1,9 @@
+2003-04-25  Richard  Henderson  <rth@redhat.com>
+
+        PR opt/10315 
+        * config/rs6000/rs6000.c (rs6000_emit_move): Only elide proper
+        checks during reload; use validize_mem instead of adjust_address.
+
 2003-04-26  Ben Elliston  <bje@wasabisystems.com>
 
        * config/arm/arm.c (arm_adjust_cost): Correct logic that tests the
index 9f9c42ac1975afe9e7b9050e1fbdc8ca5ad141d3..66e6e5205cf46b144fbb85a5eda05ddc00baa658 100644 (file)
@@ -2851,16 +2851,15 @@ rs6000_emit_move (dest, source, mode)
        }
     }
 
-  /* Handle the case where reload calls us with an invalid address;
-     and the case of CONSTANT_P_RTX.  */
-  if (!ALTIVEC_VECTOR_MODE (mode)
+  /* Handle the case where reload calls us with an invalid address.  */
+  if (reload_in_progress && mode == Pmode
       && (! general_operand (operands[1], mode)
-         || ! nonimmediate_operand (operands[0], mode)
-         || GET_CODE (operands[1]) == CONSTANT_P_RTX))
-    {
-      emit_insn (gen_rtx_SET (VOIDmode, operands[0], operands[1]));
-      return;
-    }
+         || ! nonimmediate_operand (operands[0], mode)))
+    goto emit_set;
+
+  /* Handle the case of CONSTANT_P_RTX.  */
+  if (GET_CODE (operands[1]) == CONSTANT_P_RTX)
+    goto emit_set;
   
   /* FIXME:  In the long term, this switch statement should go away
      and be replaced by a sequence of tests based on things like
@@ -3088,13 +3087,11 @@ rs6000_emit_move (dest, source, mode)
   /* Above, we may have called force_const_mem which may have returned
      an invalid address.  If we can, fix this up; otherwise, reload will
      have to deal with it.  */
-  if (GET_CODE (operands[1]) == MEM
-      && ! memory_address_p (mode, XEXP (operands[1], 0))
-      && ! reload_in_progress)
-    operands[1] = adjust_address (operands[1], mode, 0);
+  if (GET_CODE (operands[1]) == MEM && ! reload_in_progress)
+    operands[1] = validize_mem (operands[1]);
 
+ emit_set:
   emit_insn (gen_rtx_SET (VOIDmode, operands[0], operands[1]));
-  return;
 }
 \f
 /* Initialize a variable CUM of type CUMULATIVE_ARGS
This page took 0.097457 seconds and 5 git commands to generate.