https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70600
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization CC| |pinskia at gcc dot gnu.org Severity|normal |enhancement --- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> --- I have seen other cases which need to be handled by FRE/PRE instead of reassiocate. Even the simple: int f(int a, int b, int d) { unsigned a1 = a; unsigned b1 = b; unsigned c1 = a + b; int c = c1; if (d) c = a + b; return c; } Note I think FRE handles the above incorrectly as it converts the safe unsigned addition to non safe signed addition. I will file a different bug about that issue.