mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-02-10 11:29:58 +08:00
simplify-rtx.c (simplify_gen_relational): Simplify the RTX (cond (compare x y) 0) into the equivalent (cond x y).
* simplify-rtx.c (simplify_gen_relational): Simplify the RTX (cond (compare x y) 0) into the equivalent (cond x y). From-SVN: r53870
This commit is contained in:
parent
da7ac8f11b
commit
fb2c68414e
@ -1,3 +1,8 @@
|
|||||||
|
2002-05-25 Roger Sayle <roger@eyesopen.com>
|
||||||
|
|
||||||
|
* simplify-rtx.c (simplify_gen_relational): Simplify the RTX
|
||||||
|
(cond (compare x y) 0) into the equivalent (cond x y).
|
||||||
|
|
||||||
2002-05-25 Gabriel Dos Reis <gdr@codesourcery.com>
|
2002-05-25 Gabriel Dos Reis <gdr@codesourcery.com>
|
||||||
|
|
||||||
* toplev.c (output_clean_symbol_name): Use xstrdup. Fix thinko.
|
* toplev.c (output_clean_symbol_name): Use xstrdup. Fix thinko.
|
||||||
|
@ -232,6 +232,10 @@ simplify_gen_relational (code, mode, cmp_mode, op0, op1)
|
|||||||
if ((tem = simplify_relational_operation (code, cmp_mode, op0, op1)) != 0)
|
if ((tem = simplify_relational_operation (code, cmp_mode, op0, op1)) != 0)
|
||||||
return tem;
|
return tem;
|
||||||
|
|
||||||
|
/* If op0 is a compare, extract the comparison arguments from it. */
|
||||||
|
if (GET_CODE (op0) == COMPARE && op1 == const0_rtx)
|
||||||
|
op1 = XEXP (op0, 1), op0 = XEXP (op0, 0);
|
||||||
|
|
||||||
/* Put complex operands first and constants second. */
|
/* Put complex operands first and constants second. */
|
||||||
if (swap_commutative_operands_p (op0, op1))
|
if (swap_commutative_operands_p (op0, op1))
|
||||||
tem = op0, op0 = op1, op1 = tem, code = swap_condition (code);
|
tem = op0, op0 = op1, op1 = tem, code = swap_condition (code);
|
||||||
|
Loading…
Reference in New Issue
Block a user