https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68528
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Component|tree-optimization |middle-end Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot gnu.org --- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> --- The bug is that we call negate_expr_p on arg1 instead of op1 which does not preserve the sign of the operand properly. Unfortunately we do this in a lot of places. And again a TYPE_OVERFLOW_SANITIZED check was "wrong" (should have fixed the bogus case properly).