Commit 6f8e8fa
authored
[TargetLowering] Fix the problem of emulated-TLS implementation witho… (#101490)
For a __thread variable x, when emulated TLS is enabled and there is an
access to x, the compiler first looks up the symbol __emutls_v.x within
the module. However, the issue arises with an alias y of x, the compiler
still tries to look up __emutls_v.y instead of __emutls_v.x. As a
result, the lookup returns a nullptr, causing the compiler to crash. The
purpose of this MR (Merge Request) is to ensure that in emulated TLS,
before checking __emutls_v.y, the compiler first identifies which global
value y is an alias of.1 parent 64510c1 commit 6f8e8fa
File tree
2 files changed
+23
-3
lines changed- llvm
- lib/CodeGen/SelectionDAG
- test/CodeGen/AArch64
2 files changed
+23
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10245 | 10245 | | |
10246 | 10246 | | |
10247 | 10247 | | |
10248 | | - | |
10249 | | - | |
| 10248 | + | |
| 10249 | + | |
| 10250 | + | |
| 10251 | + | |
10250 | 10252 | | |
10251 | | - | |
| 10253 | + | |
| 10254 | + | |
10252 | 10255 | | |
10253 | 10256 | | |
10254 | 10257 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
0 commit comments