https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112294
Bug ID: 112294
Summary: thread_local13.C and thread_local14.C fail on
x86_64-darwin
Product: gcc
Version: 14.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: fxcoudert at gcc dot gnu.org
Target Milestone: ---
The following test failures:
FAIL: g++.dg/tls/thread_local13.C -std=gnu++14 execution test
FAIL: g++.dg/tls/thread_local13.C -std=gnu++17 execution test
FAIL: g++.dg/tls/thread_local13.C -std=gnu++20 execution test
FAIL: g++.dg/tls/thread_local14.C -std=gnu++14 execution test
FAIL: g++.dg/tls/thread_local14.C -std=gnu++17 execution test
FAIL: g++.dg/tls/thread_local14.C -std=gnu++20 execution test
have been present in (at least) GCC 14 and 13 for some months:
https://gcc.gnu.org/pipermail/gcc-testresults/2023-May/783122.html
The runtime failure is a segfault, and the backtrace (obtained by adding -g to
the compilation flags) is:
Process 72865 launched: '/Users/fx/ibin-20231029/gcc/thread_local13.exe'
(x86_64)
Process 72865 stopped
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS
(code=1, address=0x0)
frame #0: 0x0000000100003df3 thread_local13.exe`baz() at
thread_local13.C:17:13
14 {
15 while (1)
16 {
-> 17 t.foo ();
18 if (!bar ())
19 return false;
20 }
Target 0: (thread_local13.exe) stopped.
(lldb) bt
* thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS
(code=1, address=0x0)
* frame #0: 0x0000000100003df3 thread_local13.exe`baz() at
thread_local13.C:17:13
frame #1: 0x0000000100003e79 thread_local13.exe`main + 9
frame #2: 0x000000010001552e dyld`start + 462