foo (int a)
int tem = a / 5;
return tem / 3;
Note that if the expression is written without tem like a / 5 / 3,
then fold() can generate a / 15.
Will be fixed when PR 15459 is fixed (I have a slight patch for PR 15459 which I can give
to you if you want to try it).
Will be submitting the tree combiner tonight.
It might be a while for me to rewrite the tree combiner so unassigning for now.
tree-ssa-reassoc can/should be extended to do this.
Date: Mon Dec 1 13:13:28 2014
New Revision: 218211
2014-12-01 Richard Biener <email@example.com>
* Makefile.in (gimple-match.o-warn): Remove -Wno-unused-parameter,
* match.pd: Combine two successive divisions.
* gcc.dg/tree-ssa/forwprop-32.c: New testcase.