cris.md (moverside, movemside): With MEM, make sure the address is (plus reg mem).
authorHans-Peter Nilsson <hp@axis.com>
Wed, 29 Sep 2004 19:46:18 +0000 (19:46 +0000)
committerHans-Peter Nilsson <hp@gcc.gnu.org>
Wed, 29 Sep 2004 19:46:18 +0000 (19:46 +0000)
* config/cris/cris.md (moverside, movemside): With MEM, make sure
the address is (plus reg mem).

From-SVN: r88298

gcc/ChangeLog
gcc/config/cris/cris.md

index 170879c882b4e252ab20d445e10e0ef06001993a..7b1103cc6e3a67ffe5d2e6b9b84e8321871b7c49 100644 (file)
@@ -1,3 +1,8 @@
+2004-09-29  Hans-Peter Nilsson  <hp@axis.com>
+
+       * config/cris/cris.md (moverside, movemside): With MEM, make sure
+       the address is (plus reg mem).
+
 2004-09-29  David Edelsohn  <edelsohn@gnu.org>
 
        * config/rs6000/linux64.h (PROCESSOR_DEFAULT): Define.
index 6092d241b733a18e5d9b34a4454ba936813564eb..1e925dbf4baf159f7d49a363f456c3cd83398c65 100644 (file)
   rtx otherop
     = rtx_equal_p (operands[2], operands[0]) ? operands[3] : operands[2];
 
-  /* Make sure we have canonical RTX so we match the insn pattern - a
-     register or MULT in the first operand, not a constant.  */
-  if (CONSTANT_P (otherop))
+  /* Make sure we have canonical RTX so we match the insn pattern -
+     not a constant in the first operand.  We also require the order
+     (plus reg mem) to match the final pattern.  */
+  if (CONSTANT_P (otherop) || MEM_P (otherop))
     {
       operands[7] = operands[1];
       operands[8] = otherop;
   rtx otherop
     = rtx_equal_p (operands[2], operands[0]) ? operands[3] : operands[2];
 
-  /* Make sure we have canonical RTX so we match the insn pattern - a
-     register or MULT in the first operand, not a constant.  */
-  if (CONSTANT_P (otherop))
+  /* Make sure we have canonical RTX so we match the insn pattern -
+     not a constant in the first operand.  We also require the order
+     (plus reg mem) to match the final pattern.  */
+  if (CONSTANT_P (otherop) || MEM_P (otherop))
     {
       operands[7] = operands[1];
       operands[8] = otherop;