http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56990
Bug #: 56990 Summary: ICE: SIGFPE with -fsanitize=thread and empty struct Classification: Unclassified Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: sanitizer AssignedTo: unassig...@gcc.gnu.org ReportedBy: zso...@seznam.cz CC: do...@gcc.gnu.org, dvyu...@gcc.gnu.org, ja...@gcc.gnu.org, k...@gcc.gnu.org Created attachment 29891 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29891 reduced testcase Compiler output: $ gcc -fsanitize=thread testcase.c testcase.c: In function 'foo': testcase.c:3:6: internal compiler error: Floating point exception void foo(struct S *p) ^ 0xa24dbf crash_signal /mnt/svn/gcc-trunk/gcc/toplev.c:332 0xa3af12 instrument_expr /mnt/svn/gcc-trunk/gcc/tsan.c:134 0xa3c406 instrument_gimple /mnt/svn/gcc-trunk/gcc/tsan.c:612 0xa3c406 instrument_memory_accesses /mnt/svn/gcc-trunk/gcc/tsan.c:635 0xa3c406 tsan_pass /mnt/svn/gcc-trunk/gcc/tsan.c:700 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <http://gcc.gnu.org/bugs.html> for instructions. Program received signal SIGFPE, Arithmetic exception. 0x0000000000a3af12 in instrument_expr (gsi=..., expr=0x7ffff6d9f000, is_write=is_write@entry=true) at /mnt/svn/gcc-trunk/gcc/tsan.c:134 134 if (bitpos % (size * BITS_PER_UNIT) Tested revisions: r198018 - crash 4.8 r196898 - crash