Do not fold -C*ABS<n> to ABS<-C*n> (i.e., do not move negative constants
inside ABS expression). Obtained from: Richard Guenther <rguenther@suse.de> Approved by: core
This commit is contained in:
parent
df954420dd
commit
c817ff638d
@ -5661,6 +5661,9 @@ extract_muldiv_1 (tree t, tree c, enum tree_code code, tree wide_type,
|
||||
}
|
||||
break;
|
||||
}
|
||||
/* If the constant is negative, we cannot simplify this. */
|
||||
if (tree_int_cst_sgn (c) == -1)
|
||||
break;
|
||||
/* FALLTHROUGH */
|
||||
case NEGATE_EXPR:
|
||||
if ((t1 = extract_muldiv (op0, c, code, wide_type, strict_overflow_p))
|
||||
|
Loading…
Reference in New Issue
Block a user