[clang] [flang] [flang][Driver] Support -print-supported-cpus and associated aliases (PR #117199)

Andrzej WarzyƄski via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 21 10:31:50 PST 2024


================
@@ -5899,8 +5899,10 @@ def print_enabled_extensions : Flag<["-", "--"], "print-enabled-extensions">,
   HelpText<"Print the extensions enabled by the given target and -march/-mcpu options."
            " (AArch64 and RISC-V only)">,
   MarshallingInfoFlag<FrontendOpts<"PrintEnabledExtensions">>;
-def : Flag<["-"], "mcpu=help">, Alias<print_supported_cpus>;
-def : Flag<["-"], "mtune=help">, Alias<print_supported_cpus>;
+def : Flag<["-"], "mcpu=help">, Alias<print_supported_cpus>,
+  Visibility<[ClangOption, CC1Option, CLOption, FlangOption, FC1Option]>;
+def : Flag<["-"], "mtune=help">, Alias<print_supported_cpus>,
+  Visibility<[ClangOption, CC1Option, CLOption, FlangOption, FC1Option]>;
----------------
banach-space wrote:

I'd be tempted to extract these to some documented block, similar to https://github.com/llvm/llvm-project/blob/4086ead63c7e0b56b3b07873117bb7ad7a02d41c/clang/include/clang/Driver/Options.td#L3672-L3691.

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


More information about the cfe-commits mailing list