[libc-commits] [libc] [libc][patch 1/n] ensure tls dtors are called in main thread (PR #133641)

Joseph Huber via libc-commits libc-commits at lists.llvm.org
Mon Mar 31 14:40:49 PDT 2025


================
@@ -154,6 +154,9 @@ ThreadAtExitCallbackMgr *get_thread_atexit_callback_mgr() {
 }
 
 void call_atexit_callbacks(ThreadAttributes *attrib) {
+  if (attrib->dtors_called)
+    return;
+  attrib->dtors_called = true;
----------------
jhuber6 wrote:

Are these dtors thread local or something?

https://github.com/llvm/llvm-project/pull/133641


More information about the libc-commits mailing list