mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-11 23:55:18 +08:00
combine.c (gen_binary): Remove.
2004-05-25 Paolo Bonzini <bonzini@gnu.org> * combine.c (gen_binary): Remove. (known_cond, simplify_shift_const find_split_point, combine_simplify_rtx, simplify_if_then_else, simplify_set, simplify_logical, expand_field_assignment, extract_left_shift, force_to_mode, if_then_else_cond, apply_distributive_law, simplify_and_const_int, simplify_shift_const, gen_lowpart_for_combine, simplify_comparison, reversed_comparison): Replace with simplify_gen_binary, simplify_gen_relational or distribute_and_simplify_rtx. (distribute_and_simplify_rtx): New function. * simplify-rtx.c (simplify_binary_operation): Use nonzero_bits to simplify ANDs where we are turning off bits already known to be off in OP0. From-SVN: r82317
This commit is contained in:
parent
42f806e5a0
commit
dce1438a65
@ -1,3 +1,22 @@
|
||||
2004-05-25 Paolo Bonzini <bonzini@gnu.org>
|
||||
|
||||
* combine.c (gen_binary): Remove.
|
||||
(known_cond, simplify_shift_const
|
||||
find_split_point, combine_simplify_rtx,
|
||||
simplify_if_then_else, simplify_set,
|
||||
simplify_logical, expand_field_assignment,
|
||||
extract_left_shift, force_to_mode,
|
||||
if_then_else_cond, apply_distributive_law,
|
||||
simplify_and_const_int, simplify_shift_const,
|
||||
gen_lowpart_for_combine, simplify_comparison,
|
||||
reversed_comparison): Replace with
|
||||
simplify_gen_binary, simplify_gen_relational or
|
||||
distribute_and_simplify_rtx.
|
||||
(distribute_and_simplify_rtx): New function.
|
||||
* simplify-rtx.c (simplify_binary_operation):
|
||||
Use nonzero_bits to simplify ANDs where we are
|
||||
turning off bits already known to be off in OP0.
|
||||
|
||||
2004-05-27 Alan Modra <amodra@bigpond.net.au>
|
||||
|
||||
PR target/14478
|
||||
|
614
gcc/combine.c
614
gcc/combine.c
File diff suppressed because it is too large
Load Diff
@ -1844,9 +1844,11 @@ simplify_binary_operation (enum rtx_code code, enum machine_mode mode,
|
||||
case AND:
|
||||
if (trueop1 == const0_rtx && ! side_effects_p (op0))
|
||||
return const0_rtx;
|
||||
/* If we are turning off bits already known off in OP0, we need
|
||||
not do an AND. */
|
||||
if (GET_CODE (trueop1) == CONST_INT
|
||||
&& ((INTVAL (trueop1) & GET_MODE_MASK (mode))
|
||||
== GET_MODE_MASK (mode)))
|
||||
&& GET_MODE_BITSIZE (mode) <= HOST_BITS_PER_WIDE_INT
|
||||
&& (nonzero_bits (trueop0, mode) & ~INTVAL (trueop1)) == 0)
|
||||
return op0;
|
||||
if (trueop0 == trueop1 && ! side_effects_p (op0)
|
||||
&& GET_MODE_CLASS (mode) != MODE_CC)
|
||||
|
Loading…
Reference in New Issue
Block a user