https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80110
Bug ID: 80110 Summary: [6/7 Regression] error: statement marked for throw, but doesn’t w/ -fsanitize=thread Product: gcc Version: 7.0 Status: UNCONFIRMED Keywords: ice-on-valid-code Severity: normal Priority: P3 Component: sanitizer Assignee: unassigned at gcc dot gnu.org Reporter: marxin at gcc dot gnu.org CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org, jakub at gcc dot gnu.org, kcc at gcc dot gnu.org, ramana at gcc dot gnu.org Target Milestone: --- Hello. Starting from r224118, we ICE on: $ cat /tmp/tmpvu2iwxks.ii struct a { int b (); void c () { static int d = b (); } }; void f () { a e; e.c (); } $ g++ -fnon-call-exceptions -fsanitize=thread /tmp/tmpvu2iwxks.ii /tmp/tmpvu2iwxks.ii: In member function ‘void a::c()’: /tmp/tmpvu2iwxks.ii:5:3: error: statement marked for throw, but doesn’t c () ^ # .MEM_6 = VDEF <.MEM_23> _7 = __builtin___tsan_atomic8_load (&_ZGVZN1a1cEvE1d, 2); /tmp/tmpvu2iwxks.ii:5:3: internal compiler error: verify_gimple failed 0xe39786 verify_gimple_in_cfg(function*, bool) ../../gcc/tree-cfg.c:5266 0xd1aed3 execute_function_todo ../../gcc/passes.c:1966 0xd1b805 execute_todo ../../gcc/passes.c:2016