]> gcc.gnu.org Git - gcc.git/commitdiff
sparc.md (jump): Don't use the annul bit around an empty loop.
authorRichard Henderson <rth@cygnus.com>
Wed, 17 Dec 1997 15:07:39 +0000 (07:07 -0800)
committerRichard Henderson <rth@gcc.gnu.org>
Wed, 17 Dec 1997 15:07:39 +0000 (07:07 -0800)
* sparc.md (jump): Don't use the annul bit around an empty loop.
Patch from Kevin.Kelly@East.Sun.COM.

From-SVN: r17124

gcc/ChangeLog
gcc/config/sparc/sparc.md

index 1ffe005be4dff9fe94ad13a60f5cdc531cebf6a9..a7279290faf3250ad727b464d168dd3c2ce5b1ff 100644 (file)
@@ -1,3 +1,8 @@
+Wed Dec 17 15:06:04 1997  Richard Henderson  <rth@cygnus.com>
+
+       * sparc.md (jump): Don't use the annul bit around an empty loop.
+       Patch from Kevin.Kelly@East.Sun.COM.
+
 Wed Dec 17 00:51:36 1997  Stan Cox (scox@cygnus.com)
 
        * jump.c: (optimize_jump): Don't use the return register as a 
index 8ec12f5197a3920474bcf31bfb88499a9c1a1ea4..8b235fb2e4931a2f932946a2c1dd8151a7e90d86 100644 (file)
 (define_insn "jump"
   [(set (pc) (label_ref (match_operand 0 "" "")))]
   ""
-  "b%* %l0%("
+  "*
+{
+  /* Some implementations are reported to have problems with
+       foo: b,a foo
+     i.e. an empty loop with the annul bit set.  The workaround is to use 
+        foo: b foo; nop
+     instead.  */
+
+  if (flag_delayed_branch
+      && (insn_addresses[INSN_UID (operands[0])]
+         == insn_addresses[INSN_UID (insn)]))
+    return \"b %l0%#\";
+  else
+    return \"b%* %l0%(\";
+}"
   [(set_attr "type" "uncond_branch")])
 
 (define_expand "tablejump"
This page took 0.081898 seconds and 5 git commands to generate.