This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug sanitizer/81281] [6/7/8 Regression] UBSAN: false positive, dropped promotion to long type.
- From: "mpolacek at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Tue, 18 Jul 2017 15:52:47 +0000
- Subject: [Bug sanitizer/81281] [6/7/8 Regression] UBSAN: false positive, dropped promotion to long type.
- Auto-submitted: auto-generated
- References: <bug-81281-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81281
--- Comment #3 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Before that rev we had
int a = (int) (((((unsigned int) ll - (unsigned int) ci) - (unsigned int) i) +
((((unsigned int) ci - (unsigned int) ll) + (unsigned int) i) - (unsigned int)
ci)) + 2270794745);
and now just
int a = -2024172551(OVF) - (int) ci;