------- Comment #8 from jakub at gcc dot gnu dot org 2008-09-16 22:17 ------- An ifcombine optimization is certainly desirable, still IMHO it makes sense to do something about it in the FE too. The vanilla f951 generated code contains essentially 3 different conditional expressions on step > 0, and one of those is assigned to a var to be used by another COND_EXPR. One is the empty COND_EXPR, another is step > 0 ? to - from : from - to and another is ABS_EXPR <step>.
-- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=37536