[llvm] [clang] [PowerPC] Support local-dynamic TLS relocation on AIX (PR #66316)

Amy Kwan via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 1 21:01:18 PST 2024


================
@@ -145,9 +164,89 @@ namespace {
                                                               .addImm(0);
 
         if (IsAIX) {
-          // The variable offset and region handle are copied in r4 and r3. The
-          // copies are followed by GETtlsADDR32AIX/GETtlsADDR64AIX.
-          if (!IsTLSTPRelMI) {
+          if (IsTLSLDAIXMI) {
+            // The relative order between the LoadOffset at toc node, and the
----------------
amy-kwan wrote:

Question for my own clarification since it's been awhile since I have looked at this:
- Load at toc means: **any** load that loads from the TOC, right? This can mean either the load for the variable offset or the module handle?
- LoadOffset at toc means: just the load from TOC for the variable offset, right? Such as,
```
	ld 4, L..C1(2)                          # target-flags(ppc-tlsld) @x
```

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


More information about the cfe-commits mailing list