pa.md (fmpyadd peepholes): Cleanups suggested by Tege.
authorJeff Law <law@gcc.gnu.org>
Wed, 6 Jan 1993 19:41:32 +0000 (12:41 -0700)
committerJeff Law <law@gcc.gnu.org>
Wed, 6 Jan 1993 19:41:32 +0000 (12:41 -0700)
From-SVN: r3125

gcc/config/pa/pa.md

index 27296822a062c7e38f3a29d9117a28cd9e29534b..e48ca3c44365592acd301455b8f06bcbd297d12a 100644 (file)
   "*
 {
   if (GET_MODE (operands[0]) == DFmode)
-    return \"fmpyadd,dbl %1,%2,%0,%4,%3\";
+    {
+      if (rtx_equal_p (operands[5], operands[3])
+       return \"fmpyadd,dbl %1,%2,%0,%4,%3\";
+      else
+       return \"fmpyadd,dbl %1,%2,%0,%5,%3\";
+    }
   else
-    return \"fmpyadd,sgl %1,%2,%0,%4,%3\";
+    {
+      if (rtx_equal_p (operands[5], operands[3])
+       return \"fmpyadd,sgl %1,%2,%0,%4,%3\";
+      else
+       return \"fmpyadd,sgl %1,%2,%0,%5,%3\";
+    }
 }")
 
 
   "*
 {
   if (GET_MODE (operands[0]) == DFmode)
-    return \"fmpyadd,dbl %1,%2,%0,%4,%3\";
+    {
+      if (rtx_equal_p (operands[3], operands[5]))
+       return \"fmpyadd,dbl %1,%2,%0,%4,%3\";
+      else
+       return \"fmpyadd,dbl %1,%2,%0,%5,%3\";
+    }
   else
-    return \"fmpyadd,sgl %1,%2,%0,%4,%3\";
+    {
+      if (rtx_equal_p (operands[3], operands[5]))
+       return \"fmpyadd,sgl %1,%2,%0,%4,%3\";
+      else
+       return \"fmpyadd,sgl %1,%2,%0,%5,%3\";
+    }
 }")
 
 ;; Note fsub subtracts the second operand from the first while fmpysub