[Bug sanitizer/68418] ubsan complains about left shifts even with -fwrapv

2016-03-04 Thread bonzini at gnu dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68418

Paolo Bonzini  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #3 from Paolo Bonzini  ---
Fixed.

[Bug sanitizer/68418] ubsan complains about left shifts even with -fwrapv

2015-12-12 Thread bonzini at gnu dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68418

--- Comment #2 from Paolo Bonzini  ---
Author: bonzini
Date: Sat Dec 12 08:29:27 2015
New Revision: 231582

URL: https://gcc.gnu.org/viewcvs?rev=231582=gcc=rev
Log:
gcc:
PR sanitizer/68418
* c-family/c-ubsan.c (ubsan_instrument_shift): Disable
sanitization of left shifts for wrapping signed types as well.

gcc/testsuite:
PR sanitizer/68418
* gcc.dg/ubsan/c99-wrapv-shift-1.c,
gcc.dg/ubsan/c99-wrapv-shift-2.c: New testcases.

Added:
trunk/gcc/testsuite/gcc.dg/ubsan/c99-wrapv-shift-1.c
trunk/gcc/testsuite/gcc.dg/ubsan/c99-wrapv-shift-2.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/c-family/c-ubsan.c
trunk/gcc/testsuite/ChangeLog

[Bug sanitizer/68418] ubsan complains about left shifts even with -fwrapv

2015-11-18 Thread bonzini at gnu dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68418

Paolo Bonzini  changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2015-11-18
   Assignee|unassigned at gcc dot gnu.org  |bonzini at gnu dot org
 Ever confirmed|0   |1

--- Comment #1 from Paolo Bonzini  ---
I have a patch.