* mips.md (trap_if): Use "$0" for the value zero.
authorJeffrey A Law <law@cygnus.com>
Tue, 1 Dec 1998 23:50:04 +0000 (23:50 +0000)
committerJeff Law <law@gcc.gnu.org>
Tue, 1 Dec 1998 23:50:04 +0000 (16:50 -0700)
From-SVN: r24053

gcc/ChangeLog
gcc/config/mips/mips.md

index 9b51c34956295eb48d3961143904e7535b3d939b..368e835fdfb1cbc08da8760492a0079c7c1edf6b 100644 (file)
@@ -1,3 +1,7 @@
+Wed Dec  2 00:47:31 1998  Jeffrey A Law  (law@cygnus.com)
+
+       * mips.md (trap_if): Use "$0" for the value zero.
+
 Tue Dec  1 20:49:49 1998  Ulrich Drepper  <drepper@cygnus.com>
                          Stephen L Moshier  <moshier@world.std.com>
                          Richard Henderson  <rth@cygnus.com>
index 09967e1050880728fee6de4d967866bca9930cb7..40eab1bc3119385fc64799537f27660074a1fd01 100644 (file)
        && REGNO (operands[1]) == 0)
       have_dep_anti = 1;
   if (! have_dep_anti)
-    if (GENERATE_BRANCHLIKELY)
-      return \"%(beql\\t%0,%1,.+8\\n\\tbreak\\t%2%)\";
-    else
-      return \"%(bne\\t%0,%1,.+12\\n\\tnop\\n\\tbreak\\t%2%)\";
+    {
+      if (GENERATE_BRANCHLIKELY)
+       {
+          if (GET_CODE (operands[1]) == CONST_INT)
+           return \"%(beql\\t%0,$0,.+8\\n\\tbreak\\t%2%)\";
+         else
+           return \"%(beql\\t%0,%1,.+8\\n\\tbreak\\t%2%)\";
+       }
+      else
+       {
+          if (GET_CODE (operands[1]) == CONST_INT)
+           return \"%(bne\\t%0,$0,.+12\\n\\tnop\\n\\tbreak\\t%2%)\";
+         else
+           return \"%(bne\\t%0,%1,.+12\\n\\tnop\\n\\tbreak\\t%2%)\";
+       }
+    }
   return \"\";
 }"
   [(set_attr "type" "unknown")