Commit 74637033 by Richard Kenner

(simplify_plus_minus): Reject "simplifications" that are too complex

in form.

From-SVN: r3733
parent 5931019b
......@@ -4015,7 +4015,17 @@ simplify_plus_minus (code, mode, op0, op1)
ncode = MINUS;
tem = simplify_binary_operation (ncode, mode, lhs, rhs);
if (tem)
/* If we got a simple object, a SUBREG of a simple
object, or a NEG, use it. Otherwise, we either got nothing
or we got something (like a NOT), which can cause an
infinite loop. */
if (tem != 0
&& ((GET_CODE (tem) == SUBREG
&& GET_RTX_CLASS (GET_CODE (SUBREG_REG (tem))) == 'o')
|| GET_CODE (tem) == NEG
|| GET_RTX_CLASS (GET_CODE (tem)) == 'o'))
{
ops[i] = tem, ops[j] = 0;
negs[i] = negs[i] && negs[j];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment