================ @@ -145,9 +164,96 @@ 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@toc node (for the + // variable offset), and the .__tls_get_mod node is being tuned + // here. It is better to put the LoadOffset@toc node after the call, + // since the LoadOffset@toc node can use clobbers r4/r5. Search for + // the pattern of two Load@toc nodes (either for the variable offset + // or for the module handle), and then move the LoadOffset@toc node + // right before the node that uses the OutReg of the .__tls_get_mod + // node. ---------------- amy-kwan wrote:
```suggestion // The relative order between the node that loads the variable offset // from the TOC, and the .__tls_get_mod node is being tuned here. // It is better to put the variable offset TOC load after the call, // since this node can use clobbers r4/r5. // Search for the pattern of the two nodes that load from the TOC // (either for the variable offset or for the module handle), and then // move the variable offset TOC load right before the node that uses the // OutReg of the .__tls_get_mod node. ``` https://github.com/llvm/llvm-project/pull/66316 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits