[clang] [CIR] Fix 'vague' linkage globals. (PR #228586)
Kunal Dubey via cfe-commits
cfe-commits at lists.llvm.org
Wed Oct 7 01:06:23 PDT 2026
================
----------------
xakep8 wrote:
```cpp
struct D { ~D(); };
template<class T> struct X {
static D d;
};
template<class T> D X<T>::d;
D *use() { return &X<int>::d; }
```
threadsafe is false, but the variable is not TLS. CIR will register its destructor with __cxa_thread_atexit instead of __cxa_atexit.
https://github.com/llvm/llvm-project/pull/228586
More information about the cfe-commits
mailing list