[PATCH] D153907: [AIX] [TOC] Add -mtocdata/-mno-tocdata options on AIX

Chris Bowler via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 18 07:30:56 PDT 2023


cebowleratibm added a comment.

The tests appear to have gone missing on the revision of this patch I reviewed.



================
Comment at: lib/CodeGen/Targets/PPC.cpp:277
+    // Is this a global variable specified by the user as toc-data?
+    bool UserSpecifiedTOC =
+        llvm::binary_search(M.getCodeGenOpts().TocDataVarsUserSpecified, GVId);
----------------
There are some code paths where you don't need to evaluate the explicit tocdata/no-tocdata if it would have been redundant to the default already specified so you could be more efficient.


================
Comment at: lib/CodeGen/Targets/PPC.cpp:283
+    assert(
+        (!UserSpecifiedTOC || !UserSpecifiedNotTOC) &&
+        "The same variable cannot be marked as both TocData and NotTocData.");
----------------
Is this to say that the driver sets the cc1 call to ensure no variable shows up in both lists?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D153907/new/

https://reviews.llvm.org/D153907



More information about the llvm-commits mailing list