(movdi matchers): Fix src/dest order in unaligned reg->reg case.
authorRichard Kenner <kenner@gcc.gnu.org>
Sun, 13 Aug 1995 23:07:17 +0000 (19:07 -0400)
committerRichard Kenner <kenner@gcc.gnu.org>
Sun, 13 Aug 1995 23:07:17 +0000 (19:07 -0400)
From-SVN: r10223

gcc/config/i960/i960.md

index a86fb67ce68f4ac88276cd83ca9233e1d2eb13b4..0befad2d0a377e0f86eb4fff44b5316c50484bf6 100644 (file)
          || (REGNO (operands[1]) & 1))
        {
          /* We normally copy the low-numbered register first.  However, if
-            the second register operand 0 is the same as the first register
-            of operand 1, we must copy in the opposite order.  */
-         if (REGNO (operands[0]) + 1 == REGNO (operands[1]))
-           return \"mov        %D0,%D1\;mov    %0,%1\";
+            the second source register is the same as the first destination
+            register, we must copy in the opposite order.  */
+         if (REGNO (operands[1]) + 1 == REGNO (operands[0]))
+           return \"mov        %D1,%D0\;mov    %1,%0\";
          else
-           return \"mov        %0,%1\;mov      %D0,%D1\";
+           return \"mov        %1,%0\;mov      %D1,%D0\";
        }
       else
        return \"movl   %1,%0\";
          || (REGNO (operands[1]) & 1))
        {
          /* We normally copy the low-numbered register first.  However, if
-            the second register operand 0 is the same as the first register
-            of operand 1, we must copy in the opposite order.  */
-         if (REGNO (operands[0]) + 1 == REGNO (operands[1]))
-           return \"mov        %D0,%D1\;mov    %0,%1\";
+            the second source register is the same as the first destination
+            register, we must copy in the opposite order.  */
+         if (REGNO (operands[1]) + 1 == REGNO (operands[0]))
+           return \"mov        %D1,%D0\;mov    %1,%0\";
          else
-           return \"mov        %0,%1\;mov      %D0,%D1\";
+           return \"mov        %1,%0\;mov      %D1,%D0\";
        }
       else
        return \"movl   %1,%0\";