[PATCH] D145021: [Clang][AIX][p] Manually claim -p in front end

Michael Francis via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 15 13:14:05 PDT 2023


francii updated this revision to Diff 505601.
francii added a comment.

Don't claim when checking for object file


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D145021

Files:
  clang/lib/Driver/ToolChains/AIX.cpp


Index: clang/lib/Driver/ToolChains/AIX.cpp
===================================================================
--- clang/lib/Driver/ToolChains/AIX.cpp
+++ clang/lib/Driver/ToolChains/AIX.cpp
@@ -164,7 +164,7 @@
   }
 
   auto getCrt0Basename = [&Args, IsArch32Bit] {
-    if (Arg *A = Args.getLastArg(options::OPT_p, options::OPT_pg)) {
+    if (Arg *A = Args.getLastArgNoClaim(options::OPT_p, options::OPT_pg)) {
       // Enable gprofiling when "-pg" is specified.
       if (A->getOption().matches(options::OPT_pg))
         return IsArch32Bit ? "gcrt0.o" : "gcrt0_64.o";


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D145021.505601.patch
Type: text/x-patch
Size: 575 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230315/4fbc5729/attachment.bin>


More information about the cfe-commits mailing list