Qt: (only gcc build) segmentation fault in render thread on exit
Seems to be the same cause as #29081. I have found this issue https://bugreports.qt.io/browse/QTBUG-133500, there are some discussion there regarding thread_local.
Backtrace:
Thread 69 "QSGRenderThread" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 6020.0x6128]
0x00007ffc771ab9f1 in std::unique_ptr<QUnifiedTimer, std::default_delete<QUnifiedTimer> >::~unique_ptr() ()
from D:\vlc-4.0.0-dev-bettersynchexperiment\plugins\gui\libqt_plugin.dll
(gdb) bt
#0 0x00007ffc771ab9f1 in std::unique_ptr<QUnifiedTimer, std::default_delete<QUnifiedTimer> >::~unique_ptr() ()
from D:\vlc-4.0.0-dev-bettersynchexperiment\plugins\gui\libqt_plugin.dll
#1 0x00007ffc75e238d9 in (anonymous namespace)::run (p=<optimized out>) at /build/mingw-w64-gcc/src/gcc/libstdc++-v3/libsupc++/atexit_thread.cc:98
#2 0x00007ffc758a8650 in _pthread_cleanup_dest (t=<optimized out>)
at /build/mingw-w64-winpthreads/src/mingw-w64-v12.0.0/mingw-w64-libraries/winpthreads/src/thread.c:999
#3 0x00007ffc758a88b2 in _pthread_cleanup_dest (t=<optimized out>)
at /build/mingw-w64-winpthreads/src/mingw-w64-v12.0.0/mingw-w64-libraries/winpthreads/src/thread.c:975
#4 __dyn_tls_pthread (hDllHandle=<optimized out>, lpreserved=<optimized out>, dwReason=<optimized out>)
at /build/mingw-w64-winpthreads/src/mingw-w64-v12.0.0/mingw-w64-libraries/winpthreads/src/thread.c:461
#5 __dyn_tls_pthread (hDllHandle=<optimized out>, dwReason=<optimized out>, lpreserved=<optimized out>)
at /build/mingw-w64-winpthreads/src/mingw-w64-v12.0.0/mingw-w64-libraries/winpthreads/src/thread.c:428
#6 0x00007ffd38d72073 in ntdll!RtlDeactivateActivationContext () from C:\WINDOWS\SYSTEM32\ntdll.dll
#7 0x00007ffd38d78030 in ntdll!RtlVirtualUnwind () from C:\WINDOWS\SYSTEM32\ntdll.dll
#8 0x00007ffd38e1c6fa in ntdll!LdrShutdownThread () from C:\WINDOWS\SYSTEM32\ntdll.dll
#9 0x00007ffd38e1bfb6 in ntdll!RtlExitUserThread () from C:\WINDOWS\SYSTEM32\ntdll.dll
#10 0x00007ffd383ce8e0 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#11 0x00007ffd38e1bf2c in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll
#12 0x0000000000000000 in ?? ()