[Bug tree-optimization/21289] New: A numeric range is spoiled by a symblic one in VRP
kazu at cs dot umass dot edu
gcc-bugzilla@gcc.gnu.org
Fri Apr 29 19:14:00 GMT 2005
Consider
int
foo (int a, int b)
{
if (a == 1)
if (a < b)
if (a == 1)
return 1;
return 0;
}
VRP does not remove the third "if" even though 'a' is known to be 1.
This is because the symbolic range obtained from the second "if"
spoils the numeric range [1, 1] obtained from the first "if".
extract_range_from_assert tries to refine a range from an ASSERT_EXPR
if there is another range previously available, but in this case,
VRP cannot prove that [1,1] and [-INF, b-1] intersects,
it does not refine a range.
--
Summary: A numeric range is spoiled by a symblic one in VRP
Product: gcc
Version: unknown
Status: UNCONFIRMED
Keywords: missed-optimization
Severity: enhancement
Priority: P2
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: kazu at cs dot umass dot edu
CC: dnovillo at redhat dot com,gcc-bugs at gcc dot gnu dot
org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21289
More information about the Gcc-bugs
mailing list