Skip to content

Access thread-local variables via llvm.threadlocal.address - #5316

Draft
kubo39 wants to merge 1 commit into
ldc-developers:masterfrom
kubo39:use-threadlocal-address
Draft

kubo39 wants to merge 1 commit into
ldc-developers:masterfrom
kubo39:use-threadlocal-address

Conversation

@kubo39

@kubo39 kubo39 commented Nov 2, 2026

Copy link
Copy Markdown
Contributor

Like clang, wrap TLS accesses in llvm.threadlocal.address so that LLVM can CSE/LICM the TLS address computation, e.g. avoiding repeated __tls_get_addr calls with the global-dynamic model.

Like clang, wrap TLS accesses in llvm.threadlocal.address so
that LLVM can CSE/LICM the TLS address computation, e.g. avoiding
repeated __tls_get_addr calls with the global-dynamic model.
@kubo39
kubo39 force-pushed the use-threadlocal-address branch from 286c2e7 to 156d80f Compare November 2, 2026 23:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant