mirror of git://gcc.gnu.org/git/gcc.git
simplify-rtx.c (simplify_binary_operation_1): Do not simplify a division of 0 if non-call exceptions are enabled.
* simplify-rtx.c (simplify_binary_operation_1) <UDIV>: Do not simplify a division of 0 if non-call exceptions are enabled. From-SVN: r249188
This commit is contained in:
parent
85c1b6d7c8
commit
9348614880
|
|
@ -1,3 +1,8 @@
|
||||||
|
2017-06-14 Eric Botcazou <ebotcazou@adacore.com>
|
||||||
|
|
||||||
|
* simplify-rtx.c (simplify_binary_operation_1) <UDIV>: Do not simplify
|
||||||
|
a division of 0 if non-call exceptions are enabled.
|
||||||
|
|
||||||
2017-06-14 Andrew Pinski <apinski@cavium.com>
|
2017-06-14 Andrew Pinski <apinski@cavium.com>
|
||||||
Naveen H.S <Naveen.Hurugalawadi@cavium.com>
|
Naveen H.S <Naveen.Hurugalawadi@cavium.com>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3194,7 +3194,8 @@ simplify_binary_operation_1 (enum rtx_code code, machine_mode mode,
|
||||||
|
|
||||||
case UDIV:
|
case UDIV:
|
||||||
/* 0/x is 0 (or x&0 if x has side-effects). */
|
/* 0/x is 0 (or x&0 if x has side-effects). */
|
||||||
if (trueop0 == CONST0_RTX (mode))
|
if (trueop0 == CONST0_RTX (mode)
|
||||||
|
&& !cfun->can_throw_non_call_exceptions)
|
||||||
{
|
{
|
||||||
if (side_effects_p (op1))
|
if (side_effects_p (op1))
|
||||||
return simplify_gen_binary (AND, mode, op1, trueop0);
|
return simplify_gen_binary (AND, mode, op1, trueop0);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue