http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57904
--- Comment #8 from Jeffrey A. Law <law at redhat dot com> --- I wonder if we could refactor propgate_rhs_into_lhs from tree-ssa-dom.c to help here. It was designed to handle precisely this kind of problem.