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

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jun 27 12:57:51 PDT 2023


MaskRay added inline comments.


================
Comment at: clang/include/clang/Basic/DiagnosticFrontendKinds.td:93
   InGroup<BackendWarningAttributes>;
+def warn_toc_unsupported_type : Warning<"The -mtocdata option is ignored "
+  "for %0 because %1.">, InGroup<BackendWarningAttributes>;
----------------
More conventionally, we use a driver warning in `DiagnosticDriverKinds.td`. Please read https://llvm.org/docs/CodingStandards.html#error-and-warning-messages

In Clang, the conventional message reads: `ignoring ... because ...`


================
Comment at: clang/include/clang/Driver/Options.td:2921
   MarshallingInfoStringVector<CodeGenOpts<"PassPlugins">>;
+def mtocdata_EQ : CommaJoined<["-"], "mtocdata=">,
+  Flags<[CoreOption, CC1Option]>,
----------------
Make sure AIX-specific options have `TargetSpecific` flag.


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

https://reviews.llvm.org/D153907



More information about the llvm-commits mailing list