[llvm] [AMDGPU] IGLP: Fix static variables (PR #137549)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 16 08:24:25 PDT 2026
arsenm wrote:
> This needs to be fixed, but thread safety isn't something we need to worry about in LLVM. LLVM has a lot of global state that can't really work in a multithreaded environment without proper protection.
This is not true, and it is something we need to worry about. You can have different LLVMContexts in different threads for parallel compilers.
Additionally not all use cases are single compile per process. Any runtime compile environment will be reading dirty state from the last compile, which is fully sequential
https://github.com/llvm/llvm-project/pull/137549
More information about the llvm-commits
mailing list