aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorLars Brinkhoff <lars@nocrew.org>2001-02-18 20:24:10 +0000
committerRichard Henderson <rth@gcc.gnu.org>2001-02-18 12:24:10 -0800
commite1078cfca6ce48820c55353664830ad13d567ae3 (patch)
tree5d838e7d876763a62364f10f9e0ecd0823a85c0b /gcc
parent3bd241172417b6329baf196858143269c4b362e5 (diff)
downloadgcc-e1078cfca6ce48820c55353664830ad13d567ae3.zip
gcc-e1078cfca6ce48820c55353664830ad13d567ae3.tar.gz
gcc-e1078cfca6ce48820c55353664830ad13d567ae3.tar.bz2
optabs.c (expand_abs): Remove reference to HAVE_contitional_arithmetic.
* optabs.c (expand_abs): Remove reference to HAVE_contitional_arithmetic. * combine.c (simplify_set): Likewise. From-SVN: r39844
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/combine.c63
-rw-r--r--gcc/optabs.c6
3 files changed, 7 insertions, 68 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 3e663b3..63b25d5 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2001-02-18 Lars Brinkhoff <lars@nocrew.org>
+
+ * optabs.c (expand_abs): Remove reference to
+ HAVE_contitional_arithmetic.
+ * combine.c (simplify_set): Likewise.
+
2001-02-18 Richard Henderson <rth@redhat.com>
* ifcvt.c (dead_or_predicable): Don't move code if eh regions
diff --git a/gcc/combine.c b/gcc/combine.c
index c2fa5bb..b5735be 100644
--- a/gcc/combine.c
+++ b/gcc/combine.c
@@ -5229,69 +5229,6 @@ simplify_set (x)
src = SET_SRC (x);
}
-#ifdef HAVE_conditional_arithmetic
- /* If we have conditional arithmetic and the operand of a SET is
- a conditional expression, replace this with an IF_THEN_ELSE.
- We can either have a conditional expression or a MULT of that expression
- with a constant. */
- if ((GET_RTX_CLASS (GET_CODE (src)) == '1'
- || GET_RTX_CLASS (GET_CODE (src)) == '2'
- || GET_RTX_CLASS (GET_CODE (src)) == 'c')
- && (GET_RTX_CLASS (GET_CODE (XEXP (src, 0))) == '<'
- || (GET_CODE (XEXP (src, 0)) == MULT
- && GET_RTX_CLASS (GET_CODE (XEXP (XEXP (src, 0), 0))) == '<'
- && GET_CODE (XEXP (XEXP (src, 0), 1)) == CONST_INT)))
- {
- rtx cond = XEXP (src, 0);
- rtx true_val = const1_rtx;
- rtx false_arm, true_arm;
- rtx reversed;
-
- if (GET_CODE (cond) == MULT)
- {
- true_val = XEXP (cond, 1);
- cond = XEXP (cond, 0);
- }
-
- if (GET_RTX_CLASS (GET_CODE (src)) == '1')
- {
- true_arm = gen_unary (GET_CODE (src), GET_MODE (src),
- GET_MODE (XEXP (src, 0)), true_val);
- false_arm = gen_unary (GET_CODE (src), GET_MODE (src),
- GET_MODE (XEXP (src, 0)), const0_rtx);
- }
- else
- {
- true_arm = gen_binary (GET_CODE (src), GET_MODE (src),
- true_val, XEXP (src, 1));
- false_arm = gen_binary (GET_CODE (src), GET_MODE (src),
- const0_rtx, XEXP (src, 1));
- }
-
- /* Canonicalize if true_arm is the simpler one. */
- if (GET_RTX_CLASS (GET_CODE (true_arm)) == 'o'
- && GET_RTX_CLASS (GET_CODE (false_arm)) != 'o'
- && (reversed = reversed_comparison_code (cond, GET_MODE (cond),
- XEXP (cond, 0),
- XEXP (cond, 1))))
- {
- rtx temp = true_arm;
-
- true_arm = false_arm;
- false_arm = temp;
-
- cond = reversed;
- }
-
- src = gen_rtx_combine (IF_THEN_ELSE, GET_MODE (src),
- gen_rtx_combine (GET_CODE (cond), VOIDmode,
- XEXP (cond, 0),
- XEXP (cond, 1)),
- true_arm, false_arm);
- SUBST (SET_SRC (x), src);
- }
-#endif
-
/* If either SRC or DEST is a CLOBBER of (const_int 0), make this
whole thing fail. */
if (GET_CODE (src) == CLOBBER && XEXP (src, 0) == const0_rtx)
diff --git a/gcc/optabs.c b/gcc/optabs.c
index 38ff991..aa7108a 100644
--- a/gcc/optabs.c
+++ b/gcc/optabs.c
@@ -2320,11 +2320,8 @@ expand_abs (mode, op0, target, result_unsignedp, safe)
/* If this machine has expensive jumps, we can do integer absolute
value of X as (((signed) x >> (W-1)) ^ x) - ((signed) x >> (W-1)),
- where W is the width of MODE. But don't do this if the machine has
- conditional arithmetic since the branches will be converted into
- a conditional negation insn. */
+ where W is the width of MODE. */
-#ifndef HAVE_conditional_arithmetic
if (GET_MODE_CLASS (mode) == MODE_INT && BRANCH_COST >= 2)
{
rtx extended = expand_shift (RSHIFT_EXPR, mode, op0,
@@ -2340,7 +2337,6 @@ expand_abs (mode, op0, target, result_unsignedp, safe)
if (temp != 0)
return temp;
}
-#endif
/* If that does not win, use conditional jump and negate. */