aboutsummaryrefslogtreecommitdiff
path: root/gcc/config
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@libertysurf.fr>2004-07-08 17:25:04 +0200
committerEric Botcazou <ebotcazou@gcc.gnu.org>2004-07-08 15:25:04 +0000
commitafdbd485c8a2c7f81d5629e243ae34f2d5e90580 (patch)
treeef4d6c0d05e52ca4d128e4f92c16e4b98fe5dba4 /gcc/config
parent7c35745cbfe8a65e50014ebae515c6f58c8d1ab6 (diff)
downloadgcc-afdbd485c8a2c7f81d5629e243ae34f2d5e90580.zip
gcc-afdbd485c8a2c7f81d5629e243ae34f2d5e90580.tar.gz
gcc-afdbd485c8a2c7f81d5629e243ae34f2d5e90580.tar.bz2
re PR target/10567 (-fno-delayed-branch not honored in back-end)
PR target/10567 * config/sparc/sparc.md (update_return): Honor flag_delayed_branch. From-SVN: r84293
Diffstat (limited to 'gcc/config')
-rw-r--r--gcc/config/sparc/sparc.md14
1 files changed, 11 insertions, 3 deletions
diff --git a/gcc/config/sparc/sparc.md b/gcc/config/sparc/sparc.md
index c4f4daf..021e910 100644
--- a/gcc/config/sparc/sparc.md
+++ b/gcc/config/sparc/sparc.md
@@ -7758,9 +7758,17 @@
[(unspec:SI [(match_operand:SI 0 "register_operand" "r")
(match_operand:SI 1 "register_operand" "r")] UNSPEC_UPDATE_RETURN)]
"! TARGET_ARCH64"
- "cmp\t%1, 0\;be,a\t.+8\;add\t%0, 4, %0"
- [(set_attr "type" "multi")
- (set_attr "length" "3")])
+{
+ if (flag_delayed_branch)
+ return "cmp\t%1, 0\n\tbe,a\t.+8\n\t add\t%0, 4, %0";
+ else
+ return "cmp\t%1, 0\n\tbne\t.+12\n\t nop\n\tadd\t%0, 4, %0";
+}
+ [(set (attr "type") (const_string "multi"))
+ (set (attr "length")
+ (if_then_else (eq_attr "delayed_branch" "true")
+ (const_int 3)
+ (const_int 4)))])
(define_insn "nop"
[(const_int 0)]