http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47271
--- Comment #8 from Sebastian Pop <spop at gcc dot gnu.org> 2011-01-24 18:34:38 UTC --- The translation in predicate_all_scalar_phis assumes that the incoming edges OR up to true: it translates a phi node x = phi (y, z) into x = a ? y : z; In the testcase of this PR, the conditions of the two edges is not ORing up to true: we have something like this: x = a ? y : x; x = (!a and b) ? z : x; this is because we have a CFG containing diamond shape, and the write into x does not happen at every execution of the loop: (a and !b) should not modify the value of x. A possible solution is to filter out these cases in predicate_bbs.