r242214 - /branches/ARM/sve-branch/gcc/tree-ssa...
rsandifo@gcc.gnu.org
rsandifo@gcc.gnu.org
Fri Nov 11 17:20:00 GMT 2016
Author: rsandifo
Date: Fri Nov 11 17:20:00 2016
New Revision: 242214
URL: https://gcc.gnu.org/viewcvs?rev=242214&root=gcc&view=rev
Log:
Tighten tree-ssa-ccp.c:get_value_for_expr condition
bit_value_unop and bit_value_binop require constant values
to be INTEGER_CSTs:
gcc_assert ((rval.lattice_val == CONSTANT
&& TREE_CODE (rval.value) == INTEGER_CST)
|| wi::sext (rval.mask, TYPE_PRECISION (TREE_TYPE (rhs))) == -1);
However, when deciding whether to record a constant value,
the for_bits_p handling in get_value_for_expr used a negative
test for ADDR_EXPR:
else if (is_gimple_min_invariant (expr)
&& (!for_bits_p || TREE_CODE (expr) != ADDR_EXPR))
This patch uses a positive test for INTEGER_CST instead.
Existing tests showed the need for this once polynomial
constants are added.
Modified:
branches/ARM/sve-branch/gcc/tree-ssa-ccp.c
More information about the Gcc-cvs
mailing list