Commit 63f60ecb by Richard Kenner

Revert hunks not part of last patch.

From-SVN: r65908
parent 0d2f38ee
...@@ -4182,12 +4182,8 @@ extract_muldiv_1 (t, c, code, wide_type) ...@@ -4182,12 +4182,8 @@ extract_muldiv_1 (t, c, code, wide_type)
/* Pass the constant down and see if we can make a simplification. If /* Pass the constant down and see if we can make a simplification. If
we can, replace this expression with the inner simplification for we can, replace this expression with the inner simplification for
possible later conversion to our or some other type. */ possible later conversion to our or some other type. */
if ((t2 = convert (TREE_TYPE (op0), c)) != 0 if (0 != (t1 = extract_muldiv (op0, convert (TREE_TYPE (op0), c), code,
&& TREE_CODE (t2) == INTEGER_CST code == MULT_EXPR ? ctype : NULL_TREE)))
&& ! TREE_CONSTANT_OVERFLOW (t2)
&& (0 != (t1 = extract_muldiv (op0, t2, code,
code == MULT_EXPR
? ctype : NULL_TREE))))
return t1; return t1;
break; break;
...@@ -5482,17 +5478,13 @@ fold (expr) ...@@ -5482,17 +5478,13 @@ fold (expr)
if (TREE_CODE (parg0) == MULT_EXPR if (TREE_CODE (parg0) == MULT_EXPR
&& TREE_CODE (parg1) != MULT_EXPR) && TREE_CODE (parg1) != MULT_EXPR)
return fold (build (PLUS_EXPR, type, return fold (build (PLUS_EXPR, type,
fold (build (PLUS_EXPR, type, fold (build (PLUS_EXPR, type, parg0, marg)),
convert (type, parg0), parg1));
convert (type, marg))),
convert (type, parg1)));
if (TREE_CODE (parg0) != MULT_EXPR if (TREE_CODE (parg0) != MULT_EXPR
&& TREE_CODE (parg1) == MULT_EXPR) && TREE_CODE (parg1) == MULT_EXPR)
return fold (build (PLUS_EXPR, type, return fold (build (PLUS_EXPR, type,
fold (build (PLUS_EXPR, type, fold (build (PLUS_EXPR, type, parg1, marg)),
convert (type, parg1), parg0));
convert (type, marg))),
convert (type, parg0)));
} }
if (TREE_CODE (arg0) == MULT_EXPR && TREE_CODE (arg1) == MULT_EXPR) if (TREE_CODE (arg0) == MULT_EXPR && TREE_CODE (arg1) == MULT_EXPR)
...@@ -5824,8 +5816,7 @@ fold (expr) ...@@ -5824,8 +5816,7 @@ fold (expr)
TREE_OPERAND (arg0, 1))); TREE_OPERAND (arg0, 1)));
if (TREE_CODE (arg1) == INTEGER_CST if (TREE_CODE (arg1) == INTEGER_CST
&& 0 != (tem = extract_muldiv (TREE_OPERAND (t, 0), && 0 != (tem = extract_muldiv (TREE_OPERAND (t, 0), arg1,
convert (type, arg1),
code, NULL_TREE))) code, NULL_TREE)))
return convert (type, tem); return convert (type, tem);
......
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