[clang] bddef53 - [docs] Exclude FlangOption and re-generate ClangCommandLineReference.rst

Fangrui Song via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 15 15:22:14 PDT 2021


Author: Fangrui Song
Date: 2021-06-15T15:22:07-07:00
New Revision: bddef537776e15fa21e2ec11a4b2543d6d91fedc

URL: https://github.com/llvm/llvm-project/commit/bddef537776e15fa21e2ec11a4b2543d6d91fedc
DIFF: https://github.com/llvm/llvm-project/commit/bddef537776e15fa21e2ec11a4b2543d6d91fedc.diff

LOG: [docs] Exclude FlangOption and re-generate ClangCommandLineReference.rst

Added: 
    

Modified: 
    clang/docs/ClangCommandLineReference.rst
    clang/include/clang/Driver/ClangOptionDocs.td

Removed: 
    


################################################################################
diff  --git a/clang/docs/ClangCommandLineReference.rst b/clang/docs/ClangCommandLineReference.rst
index 356da15e67e25..54b417dcfdf98 100644
--- a/clang/docs/ClangCommandLineReference.rst
+++ b/clang/docs/ClangCommandLineReference.rst
@@ -102,9 +102,7 @@ Run the static analyzer
 
 .. option:: --analyzer-output<arg>
 
-Static analyzer report output format (html\|plist\|plist-multi-file\|plist-html\|sarif\|text).
-
-.. option:: -ansi, --ansi
+Static analyzer report output format (html\|plist\|plist-multi-file\|plist-html\|sarif\|sarif-html\|text).
 
 .. option:: -arch <arg>
 
@@ -164,6 +162,10 @@ Include PTX for the following GPU architecture (e.g. sm\_35) or 'all'. May be sp
 
 Enable device-side debug info generation. Disables ptxas optimizations.
 
+.. option:: -cuid=<arg>
+
+An ID for compilation unit, which should be the same for the same compilation unit but 
diff erent for 
diff erent compilation units. It is used to externalize device-side static variables for single source offloading languages CUDA and HIP so that they can be accessed by the host code of the same compilation unit.
+
 .. option:: -current\_version<arg>
 
 .. option:: -dead\_strip
@@ -214,14 +216,14 @@ Trivial automatic variable initialization to zero is only here for benchmarks, i
 
 .. option:: -faligned-new=<arg>
 
-.. option:: -fcuda-flush-denormals-to-zero, -fno-cuda-flush-denormals-to-zero
-
-Flush denormal floating point values to zero in CUDA device mode.
-
 .. option:: -ffixed-r19
 
 Reserve register r19 (Hexagon only)
 
+.. option:: -fgpu-flush-denormals-to-zero, -fcuda-flush-denormals-to-zero, -fno-gpu-flush-denormals-to-zero
+
+Flush denormal floating point values to zero in CUDA/HIP device mode.
+
 .. option:: -fheinous-gnu-extensions
 
 .. option:: -flat\_namespace
@@ -246,14 +248,23 @@ Specify comma-separated list of triples OpenMP offloading targets to be supporte
 
 Add -rpath with architecture-specific resource directory to the linker flags
 
-.. option:: -fsanitize-system-ignorelist=<arg>
+.. option:: -fsanitize-system-ignorelist=<arg>, -fsanitize-system-blacklist=<arg>
 
 Path to system ignorelist file for sanitizers
 
+.. option:: -fshow-skipped-includes
+
+#include files may be "skipped" due to include guard optimization
+             or #pragma once. This flag makes -H show also such includes.
+
 .. option:: -fsystem-module
 
 Build this module as a system module. Only used with -emit-module
 
+.. option:: -fuse-cuid=<arg>
+
+Method to generate ID's for compilation units for single source offloading languages CUDA and HIP: 'hash' (ID's generated by hashing file path and command line options) \| 'random' (ID's generated as random numbers) \| 'none' (disabled). Default is 'hash'. This option will be overriden by option '-cuid=\[ID\]' if it is specified.
+
 .. option:: --gcc-toolchain=<arg>, -gcc-toolchain <arg>
 
 Search for GCC installation in the specified directory on targets which commonly use GCC. The directory usually contains 'lib{,32,64}/gcc{,-cross}/$triple' and 'include'. If specified, sysroot is skipped for GCC detection. Note: executables (e.g. ld) used by the compiler are not overridden by the selected GCC installation
@@ -266,8 +277,6 @@ Generate CodeView debug information
 
 Emit type record hashes in a .debug$H section
 
-.. option:: -ginline-line-tables, -gno-inline-line-tables
-
 .. option:: --gpu-instrument-lib=<arg>
 
 Instrument device library for HIP, which is a LLVM bitcode containing \_\_cyg\_profile\_func\_enter and \_\_cyg\_profile\_func\_exit
@@ -324,6 +333,10 @@ Make the next included directory (-I or -F) an indexer header map
 
 Enforce targets of indirect branches and function returns
 
+.. option:: -menable-unsafe-fp-math
+
+Allow unsafe floating-point math optimizations which may decrease precision
+
 .. option:: -mharden-sls=<arg>
 
 Select straight-line speculation hardening scope
@@ -376,6 +389,8 @@ Disable builtin #include directories
 
 .. option:: -nogpuinc, -nocudainc
 
+Do not add include paths for CUDA/HIP and do not include the default CUDA/HIP wrapper headers
+
 .. option:: -nogpulib, -nocudalib
 
 Do not link device library for CUDA/HIP device compilation
@@ -476,7 +491,7 @@ Only modify files with a filename contained in the provided directory path
 
 .. option:: --offload-arch=<arg>, --cuda-gpu-arch=<arg>, --no-offload-arch=<arg>
 
-CUDA offloading device architecture (e.g. sm\_35), or HIP offloading target ID in the form of a device architecture followed by target ID features delimited by a colon. Each target ID feature is a pre-defined string followed by a plus or minus sign (e.g. gfx908:xnack+:sram-ecc-).  May be specified more than once.
+CUDA offloading device architecture (e.g. sm\_35), or HIP offloading target ID in the form of a device architecture followed by target ID features delimited by a colon. Each target ID feature is a pre-defined string followed by a plus or minus sign (e.g. gfx908:xnack+:sramecc-).  May be specified more than once.
 
 .. option:: -p, --profile
 
@@ -520,6 +535,10 @@ Print the library path for the currently used compiler runtime library ("libgcc.
 
 .. option:: -print-multi-lib, --print-multi-lib
 
+.. option:: -print-multiarch, --print-multiarch
+
+Print the multiarch target triple
+
 .. option:: -print-prog-name=<name>, --print-prog-name=<name>, --print-prog-name <arg>
 
 Print the full program path of <name>
@@ -528,6 +547,14 @@ Print the full program path of <name>
 
 Print the resource directory pathname
 
+.. option:: -print-rocm-search-dirs, --print-rocm-search-dirs
+
+Print the paths used for finding ROCm installation
+
+.. option:: -print-runtime-dir, --print-runtime-dir
+
+Print the directory pathname containing clangs runtime libraries
+
 .. option:: -print-search-dirs, --print-search-dirs
 
 Print the paths used for finding libraries and programs
@@ -704,7 +731,7 @@ Suppress all warnings
 
 .. option:: -whatsloaded
 
-.. option:: -whyload
+.. option:: -why\_load, -whyload
 
 .. option:: -working-directory<arg>, -working-directory=<arg>
 
@@ -776,6 +803,12 @@ Pass <arg> to the assembler
 
 Pass <arg> to the clang compiler
 
+.. option:: -ansi, --ansi
+
+.. option:: -fc++-abi=<arg>
+
+C++ ABI to use. This will override the target C++ ABI.
+
 .. option:: -fclang-abi-compat=<version>
 
 Attempt to match the ABI of Clang <version>
@@ -788,7 +821,9 @@ Treat each comma separated argument in <arg> as a documentation comment block co
 
 Require member pointer base types to be complete if they would be significant under the Microsoft ABI
 
-.. option:: -fcrash-diagnostics-dir=<arg>
+.. option:: -fcrash-diagnostics-dir=<dir>
+
+Put crash-report files in <dir>
 
 .. option:: -fdeclspec, -fno-declspec
 
@@ -814,9 +849,9 @@ Print source range spans in numeric form
 
 Discard value names in LLVM IR
 
-.. option:: -fexperimental-new-pass-manager, -fno-experimental-new-pass-manager
+.. option:: -fexperimental-relative-c++-abi-vtables, -fno-experimental-relative-c++-abi-vtables
 
-Enables an experimental new pass manager in LLVM.
+Use the experimental C++ class ABI for classes with virtual tables
 
 .. option:: -fexperimental-strict-floating-point
 
@@ -838,11 +873,15 @@ Inline suitable functions
 
 Inline functions which are (explicitly or implicitly) marked inline
 
+.. option:: -flegacy-pass-manager, -fno-experimental-new-pass-manager, -fno-legacy-pass-manager
+
+Use the legacy pass manager in LLVM
+
 .. option:: -fno-crash-diagnostics
 
 Disable auto-generation of preprocessed source files and a script for reproduction during a clang crash
 
-.. option:: -fno-sanitize-ignorelist
+.. option:: -fno-sanitize-ignorelist, -fno-sanitize-blacklist
 
 Don't use ignorelist file for sanitizers
 
@@ -850,6 +889,10 @@ Don't use ignorelist file for sanitizers
 
 .. option:: -frecord-command-line, -fno-record-command-line, -frecord-gcc-switches
 
+.. option:: -fsanitize-address-destructor=<arg>
+
+Set destructor type used in ASan instrumentation
+
 .. option:: -fsanitize-address-field-padding=<arg>
 
 Level of field padding for AddressSanitizer
@@ -862,6 +905,10 @@ Enable linker dead stripping of globals in AddressSanitizer
 
 Enable poisoning array cookies when using custom operator new\[\] in AddressSanitizer
 
+.. option:: -fsanitize-address-use-after-return=<mode>
+
+Select the mode of detecting stack use-after-return in AddressSanitizer
+
 .. option:: -fsanitize-address-use-after-scope, -fno-sanitize-address-use-after-scope
 
 Enable use-after-scope detection in AddressSanitizer
@@ -870,21 +917,6 @@ Enable use-after-scope detection in AddressSanitizer
 
 Enable ODR indicator globals to avoid false ODR violation reports in partially sanitized programs at the cost of an increase in binary size
 
-.. option:: -fsanitize-address-destructor=<arg>
-
-Set the kind of module destructors emitted by AddressSanitizer instrumentation.
-These destructors are emitted to unregister instrumented global variables when
-code is unloaded (e.g. via `dlclose()`).
-
-Valid options are:
-
-* ``global`` - Emit module destructors that are called via a platform specific array (see `llvm.global_dtors`).
-* ``none`` - Do not emit module destructors.
-
-.. option:: -fsanitize-ignorelist=<arg>
-
-Path to ignorelist file for sanitizers
-
 .. option:: -fsanitize-cfi-canonical-jump-tables, -fno-sanitize-cfi-canonical-jump-tables
 
 Make the jump table addresses canonical in the symbol table
@@ -897,12 +929,11 @@ Enable control flow integrity (CFI) checks for cross-DSO calls.
 
 Generalize pointers in CFI indirect call type signature checks
 
-.. option:: -fsanitize-coverage-allowlist=<arg>
+.. option:: -fsanitize-coverage-allowlist=<arg>, -fsanitize-coverage-whitelist=<arg>
 
-Restrict sanitizer coverage instrumentation exclusively to modules and
-functions that match the provided special case list, except the blocked ones
+Restrict sanitizer coverage instrumentation exclusively to modules and functions that match the provided special case list, except the blocked ones
 
-.. option:: -fsanitize-coverage-ignorelist=<arg>
+.. option:: -fsanitize-coverage-ignorelist=<arg>, -fsanitize-coverage-blacklist=<arg>, -fsanitize-coverage-blocklist=<arg>
 
 Disable sanitizer coverage instrumentation for modules and functions that match the provided special case list, even the allowed ones
 
@@ -914,6 +945,14 @@ Specify the type of coverage instrumentation for Sanitizers
 
 Select the HWAddressSanitizer ABI to target (interceptor or platform, default interceptor). This option is currently unused.
 
+.. option:: -fsanitize-hwaddress-experimental-aliasing, -fno-sanitize-hwaddress-experimental-aliasing
+
+Enable aliasing mode in HWAddressSanitizer
+
+.. option:: -fsanitize-ignorelist=<arg>, -fsanitize-blacklist=<arg>
+
+Path to ignorelist file for sanitizers
+
 .. option:: -fsanitize-link-c++-runtime, -fno-sanitize-link-c++-runtime
 
 .. option:: -fsanitize-link-runtime, -fno-sanitize-link-runtime
@@ -970,6 +1009,10 @@ Turn on runtime checks for various forms of undefined or suspicious behavior. Se
 
 Enable function outlining (AArch64 only)
 
+.. option:: -moutline-atomics, -mno-outline-atomics
+
+Generate local calls to out-of-line atomic operations
+
 .. option:: --param <arg>, --param=<arg>
 
 .. option:: -print-supported-cpus, --print-supported-cpus, -mcpu=?, -mtune=?
@@ -1028,7 +1071,7 @@ Flags controlling how ``#include``\s are resolved to files.
 
 .. option:: -I<dir>, --include-directory <arg>, --include-directory=<arg>
 
-Add directory to include search path. For C++ input, if
+Add directory to include search path. For C++ inputs, if
 there are multiple -I options, these directories are searched
 in the order they are given before the standard system directories
 are searched. If the same directory is in the SYSTEM include search
@@ -1039,6 +1082,10 @@ will be ignored
 
 Restrict all prior -I flags to double-quoted inclusion and remove current directory from include path
 
+.. option:: --amdgpu-arch-tool=<arg>
+
+Tool used for detecting AMD GPU arch in the system.
+
 .. option:: --cuda-path-ignore-env
 
 Ignore environment variables to detect CUDA installation
@@ -1095,6 +1142,10 @@ Validate the system headers that a module depends on when loading the module
 
 Specify the prebuilt module path
 
+.. option:: --hip-path=<arg>
+
+HIP runtime installation path, used for finding HIP version and adding HIP include path.
+
 .. option:: -idirafter<arg>, --include-directory-after <arg>, --include-directory-after=<arg>
 
 Add directory to AFTER include search path
@@ -1155,6 +1206,10 @@ Set directory to include search path with prefix
 
 Add directory to SYSTEM include search path, absolute paths are relative to -isysroot
 
+.. option:: --libomptarget-amdgcn-bc-path=<arg>
+
+Path to libomptarget-amdgcn bitcode library
+
 .. option:: --libomptarget-nvptx-bc-path=<arg>
 
 Path to libomptarget-nvptx bitcode library
@@ -1290,6 +1345,8 @@ Target-independent compilation options
 
 .. option:: -fPIE, -fno-PIE
 
+.. option:: -faccess-control, -fno-access-control
+
 .. option:: -faddrsig, -fno-addrsig
 
 Emit an address-significance table
@@ -1348,6 +1405,10 @@ Restrict code to those available for App Extensions
 
 .. option:: -fastf
 
+.. option:: -fasync-exceptions, -fno-async-exceptions
+
+Enable EH Asynchronous exceptions
+
 .. option:: -fasynchronous-unwind-tables, -fno-asynchronous-unwind-tables
 
 .. option:: -fautolink, -fno-autolink
@@ -1356,6 +1417,10 @@ Restrict code to those available for App Extensions
 
 Generate labels for each basic block or place each basic block or a subset of basic blocks in its own section.
 
+.. option:: -fbinutils-version=<major.minor>
+
+Produced object files can use all ELF features supported by this binutils version and newer. If -fno-integrated-as is specified, the generated assembly will consider GNU as support. 'none' means that all ELF features can be used, regardless of binutils support. Defaults to 2.26.
+
 .. option:: -fblocks, -fno-blocks
 
 Enable the 'blocks' language feature
@@ -1374,7 +1439,9 @@ Accept non-standard constructs supported by the Borland compiler
 
 Load the clang builtins module map file.
 
+.. program:: clang1
 .. option:: -fc++-static-destructors, -fno-c++-static-destructors
+.. program:: clang
 
 .. option:: -fcaret-diagnostics, -fno-caret-diagnostics
 
@@ -1418,10 +1485,18 @@ Assume functions may be convergent
 
 Enable support for the C++ Coroutines TS
 
+.. option:: -fcoverage-compilation-dir=<arg>
+
+The compilation directory to embed in the coverage mapping.
+
 .. option:: -fcoverage-mapping, -fno-coverage-mapping
 
 Generate coverage mapping to enable code coverage analysis
 
+.. option:: -fcoverage-prefix-map=<arg>
+
+remap file source paths in coverage mapping
+
 .. option:: -fcreate-profile
 
 .. option:: -fcs-profile-generate
@@ -1452,9 +1527,9 @@ Enable C++ exceptions
 
 Place each data in its own section
 
-.. option:: -fdebug-compilation-dir <arg>, -fdebug-compilation-dir=<arg>
+.. option:: -fdebug-compilation-dir=<arg>, -fdebug-compilation-dir <arg>
 
-The compilation directory to embed in the debug info.
+The compilation directory to embed in the debug info
 
 .. option:: -fdebug-default-version=<arg>
 
@@ -1504,9 +1579,9 @@ Print absolute paths in diagnostics
 .. option:: -fdiagnostics-color=<arg>
 .. program:: clang
 
-.. option:: -fdiagnostics-hotness-threshold=<number>
+.. option:: -fdiagnostics-hotness-threshold=<value>
 
-Prevent optimization remarks from being output if they do not have at least this profile count
+Prevent optimization remarks from being output if they do not have at least this profile count. Use 'auto' to apply the threshold from profile summary
 
 .. option:: -fdiagnostics-show-hotness, -fno-diagnostics-show-hotness
 
@@ -1528,6 +1603,10 @@ Print a template comparison tree for 
diff ering templates
 
 Enable alternative token representations '<:', ':>', '<%', '%>', '%:', '%:%:' (default)
 
+.. option:: -fdirect-access-external-data, -fno-direct-access-external-data
+
+Don't use GOT indirection to reference external data symbols
+
 .. option:: -fdollars-in-identifiers, -fno-dollars-in-identifiers
 
 Allow '$' in identifiers
@@ -1582,20 +1661,28 @@ Enable support for exception handling
 
 Enable the experimental new constant interpreter
 
-.. option:: -fexperimental-relative-c++-abi-vtables, -fno-experimental-relative-c++-abi-vtables
+.. option:: -fextdirs=<arg>, --extdirs <arg>, --extdirs=<arg>
 
-Use the experimental C++ class ABI for classes with virtual tables
+.. option:: -fextend-arguments=<arg>
 
-.. option:: -fextdirs=<arg>, --extdirs <arg>, --extdirs=<arg>
+Controls how scalar integer arguments are extended in calls to unprototyped and varargs functions
 
 .. option:: -ffast-math, -fno-fast-math
 
 Allow aggressive, lossy floating-point optimizations
 
+.. option:: -ffile-compilation-dir=<arg>
+
+The compilation directory to embed in the debug info and coverage mapping.
+
 .. option:: -ffile-prefix-map=<arg>
 
 remap file source paths in debug info and predefined preprocessor macros
 
+.. option:: -ffinite-loops, -fno-finite-loops
+
+Assume all loops are finite.
+
 .. option:: -ffinite-math-only, -fno-finite-math-only
 
 .. option:: -ffixed-point, -fno-fixed-point
@@ -1618,7 +1705,7 @@ Enable support for int128\_t type
 
 .. option:: -ffp-contract=<arg>
 
-Form fused FP ops (e.g. FMAs): fast (everywhere) \| on (according to FP\_CONTRACT pragma) \| off (never fuse). Default is 'fast' for CUDA/HIP and 'on' otherwise.
+Form fused FP ops (e.g. FMAs): fast (fuses across statements disregarding pragmas) \| on (only fuses in the same statement unless dictated by pragmas) \| off (never fuses) \| fast-honor-pragmas (fuses across statements unless diectated by pragmas). Default is 'fast' for CUDA, 'fast-honor-pragmas' for HIP, and 'on' otherwise.
 
 .. option:: -ffp-exception-behavior=<arg>
 
@@ -1656,7 +1743,7 @@ Sets various macros to claim compatibility with the given GCC version (default i
 
 .. option:: -fgpu-allow-device-init, -fno-gpu-allow-device-init
 
-Allow device side init function in HIP
+Allow device side init function in HIP (experimental)
 
 .. option:: -fgpu-defer-diag, -fno-gpu-defer-diag
 
@@ -1666,6 +1753,14 @@ Defer host/device related diagnostic messages for CUDA/HIP
 
 Generate relocatable device code, also known as separate compilation mode
 
+.. option:: -fgpu-sanitize, -fno-gpu-sanitize
+
+Enable sanitizer for AMDGPU target
+
+.. option:: -fhip-fp32-correctly-rounded-divide-sqrt, -fno-hip-fp32-correctly-rounded-divide-sqrt
+
+Specify that single precision floating-point divide and sqrt used in the program source are correctly rounded (HIP device compilation only)
+
 .. option:: -fhip-new-launch-api, -fno-hip-new-launch-api
 
 Use new kernel launching API for HIP
@@ -1688,6 +1783,8 @@ Implicitly search the file system for module map files.
 
 .. option:: -finput-charset=<arg>
 
+Specify the default character set for source files
+
 .. option:: -finstrument-function-entry-bare
 
 Instrument function entry only, after inlining, without arguments to the instrumentation call
@@ -1736,6 +1833,14 @@ Controls the backend parallelism of -flto=thin (default of 0 means the number of
 
 Set LTO mode to either 'full' or 'thin'
 
+.. program:: clang2
+.. option:: -flto=auto
+.. program:: clang
+
+.. program:: clang3
+.. option:: -flto=jobserver
+.. program:: clang
+
 .. option:: -fmacro-backtrace-limit=<arg>
 
 .. option:: -fmath-errno, -fno-math-errno
@@ -1754,6 +1859,12 @@ Specify the maximum alignment to enforce on pointers lacking an explicit alignme
 
 Enable heap memory profiling
 
+.. program:: clang1
+.. option:: -fmemory-profile=<directory>
+.. program:: clang
+
+Enable heap memory profiling and dump results into <directory>
+
 .. option:: -fmerge-all-constants, -fno-merge-all-constants
 
 Allow merging of constants
@@ -1768,7 +1879,7 @@ Format message diagnostics so that they fit within N columns
 
 Load this module map file
 
-.. option:: -fmodule-name=<name>, -fmodule-implementation-of <arg>, -fmodule-name <arg>
+.. option:: -fmodule-name=<name>, -fmodule-implementation-of <arg>
 
 Specify the name of the module to build
 
@@ -1832,8 +1943,6 @@ Specifies the largest alignment guaranteed by '::operator new(size\_t)'
 
 .. option:: -fnext-runtime
 
-.. option:: -fno-access-control, -fno-no-access-control
-
 .. option:: -fno-builtin-<arg>
 
 Disable implicit builtin knowledge of a specific function
@@ -1844,10 +1953,6 @@ Do not elide types when printing diagnostics
 
 .. option:: -fno-max-type-align
 
-.. option:: -fno-operator-names
-
-Do not treat C++ operator name keywords as synonyms for operators
-
 .. option:: -fno-strict-modules-decluse
 
 .. option:: -fno-temp-file
@@ -1876,6 +1981,14 @@ Use EH-safe code when synthesizing retains and releases in -fobjc-arc
 
 .. option:: -fobjc-convert-messages-to-runtime-calls, -fno-objc-convert-messages-to-runtime-calls
 
+.. option:: -fobjc-disable-direct-methods-for-testing
+
+Ignore attribute objc\_direct so that direct methods can be tested
+
+.. option:: -fobjc-encode-cxx-class-template-spec, -fno-objc-encode-cxx-class-template-spec
+
+Fully encode c++ class template specialization
+
 .. option:: -fobjc-exceptions, -fno-objc-exceptions
 
 Enable Objective-C exceptions
@@ -1900,6 +2013,16 @@ Specify the target Objective-C runtime kind and version
 
 Enable ARC-style weak references in Objective-C
 
+.. option:: -foffload-lto, -fno-offload-lto
+
+Enable LTO in 'full' mode for offload compilation
+
+.. program:: clang1
+.. option:: -foffload-lto=<arg>
+.. program:: clang
+
+Set LTO mode to either 'full' or 'thin' for offload compilation
+
 .. option:: -fomit-frame-pointer, -fno-omit-frame-pointer
 
 .. option:: -fopenmp, -fno-openmp
@@ -1918,6 +2041,8 @@ Emit OpenMP code only for SIMD-based constructs.
 
 .. option:: -foperator-arrow-depth=<arg>
 
+.. option:: -foperator-names, -fno-operator-names
+
 .. option:: -foptimization-record-file=<file>
 
 Specify the output name of the file containing the optimization remarks. Implies -fsave-optimization-record. On Darwin platforms, this cannot be used with multiple -arch <arch> options.
@@ -1986,8 +2111,22 @@ Validate PCH input files based on content if mtime 
diff ers
 
 Load the named plugin (dynamic shared object)
 
+.. option:: -fprebuilt-implicit-modules, -fno-prebuilt-implicit-modules
+
+Look up implicit modules in the prebuilt module path
+
 .. option:: -fpreserve-as-comments, -fno-preserve-as-comments
 
+.. option:: -fproc-stat-report<arg>
+
+Print subprocess statistics
+
+.. program:: clang1
+.. option:: -fproc-stat-report=<arg>
+.. program:: clang
+
+Save subprocess statistics to the given file
+
 .. option:: -fprofile-arcs, -fno-profile-arcs
 
 .. option:: -fprofile-dir=<arg>
@@ -2028,7 +2167,11 @@ Generate instrumented code to collect execution counts into <file> (overridden b
 
 Use instrumentation data for profile-guided optimization
 
-.. option:: -fprofile-remapping-file=<file>, -fprofile-remapping-file <arg>
+.. option:: -fprofile-list=<arg>
+
+Filename defining the list of functions/files to instrument
+
+.. option:: -fprofile-remapping-file=<file>
 
 Use the remappings described in <file> to match the profile data against names in the program
 
@@ -2057,11 +2200,9 @@ Set update method of profile counters (atomic,prefer-atomic,single)
 
 Use instrumentation data for profile-guided optimization. If pathname is a directory, it reads from <pathname>/default.profdata. Otherwise, it reads from file <pathname>.
 
-.. program:: clang1
-.. option:: -fprofile-list=<file>
-.. program:: clang
+.. option:: -fpseudo-probe-for-profiling, -fno-pseudo-probe-for-profiling
 
-Filename defining the list of functions/files to instrument. The file uses the sanitizer special case list format.
+Emit pseudo probes for sample profiling
 
 .. option:: -freciprocal-math, -fno-reciprocal-math
 
@@ -2089,11 +2230,7 @@ Turn on loop reroller
 
 .. option:: -frewrite-includes, -fno-rewrite-includes
 
-.. option:: -frewrite-map-file <arg>
-
-.. program:: clang1
 .. option:: -frewrite-map-file=<arg>
-.. program:: clang
 
 .. option:: -fropi, -fno-ropi
 
@@ -2179,7 +2316,9 @@ Enables splitting of the LTO unit
 
 Enable late function splitting using profile information (x86 ELF)
 
-.. option:: -fsplit-stack
+.. option:: -fsplit-stack, -fno-split-stack
+
+Use segmented stack
 
 .. option:: -fstack-clash-protection, -fno-stack-clash-protection
 
@@ -2201,6 +2340,10 @@ Enable stack protectors for some functions vulnerable to stack smashing. Compare
 
 Emit section containing metadata on function stack sizes
 
+.. option:: -fstack-usage
+
+Emit .su file containing information on function stack sizes
+
 .. option:: -fstandalone-debug, -fno-limit-debug-info, -fno-standalone-debug
 
 Emit full debug info for all types used by the program
@@ -2249,6 +2392,12 @@ Perform ThinLTO importing using provided function summary index
 
 .. option:: -ftime-report
 
+.. program:: clang1
+.. option:: -ftime-report=<arg>
+.. program:: clang
+
+(For new pass manager) "per-pass": one report for each pass; "per-pass-run": one report for each pass invocation
+
 .. option:: -ftime-trace
 
 
@@ -2346,11 +2495,27 @@ Generate verbose assembly output
 
 Enables dead virtual function elimination optimization. Requires -flto=full
 
+.. option:: -fvisibility-dllexport=<arg>
+
+The visibility for dllexport defintions \[-fvisibility-from-dllstorageclass\]
+
+.. option:: -fvisibility-externs-dllimport=<arg>
+
+The visibility for dllimport external declarations \[-fvisibility-from-dllstorageclass\]
+
+.. option:: -fvisibility-externs-nodllstorageclass=<arg>
+
+The visibility for external declarations without an explicit DLL dllstorageclass \[-fvisibility-from-dllstorageclass\]
+
+.. option:: -fvisibility-from-dllstorageclass, -fno-visibility-from-dllstorageclass
+
+Set the visiblity of symbols in the generated code from their DLL storage class
+
 .. option:: -fvisibility-global-new-delete-hidden
 
 Give global C++ operator new and delete declarations hidden visibility
 
-.. option:: -fvisibility-inlines-hidden
+.. option:: -fvisibility-inlines-hidden, -fno-visibility-inlines-hidden
 
 Give inline C++ member functions hidden visibility by default
 
@@ -2362,10 +2527,16 @@ When -fvisibility-inlines-hidden is enabled, static variables in inline C++ memb
 
 Give global types 'default' visibility and global functions and variables 'hidden' visibility by default
 
+.. option:: -fvisibility-nodllstorageclass=<arg>
+
+The visibility for defintiions without an explicit DLL export class \[-fvisibility-from-dllstorageclass\]
+
 .. option:: -fvisibility=<arg>
 
 Set the default symbol visibility for all global declarations
 
+.. option:: -fwarn-stack-size=<arg>
+
 .. option:: -fwasm-exceptions
 
 Use WebAssembly style exceptions
@@ -2382,6 +2553,10 @@ Treat signed integer overflow as two's complement
 
 Store string literals as writable data
 
+.. option:: -fxl-pragma-pack, -fno-xl-pragma-pack
+
+Enable IBM XL #pragma pack handling
+
 .. option:: -fxray-always-emit-customevents, -fno-xray-always-emit-customevents
 
 Always emit \_\_xray\_customevent(...) calls even if the containing function is not always instrumented
@@ -2446,8 +2621,14 @@ When using -fxray-function-groups, select which group of functions to instrument
 
 Enable System z vector language extension
 
+.. option:: --gpu-bundle-output, --no-gpu-bundle-output
+
+Bundle output files of HIP device compilation
+
 .. option:: -pedantic, --pedantic, -no-pedantic, --no-pedantic
 
+Warn on language extensions
+
 .. option:: -pedantic-errors, --pedantic-errors
 
 OpenCL flags
@@ -2480,6 +2661,10 @@ OpenCL only. Allow use of less precise MAD computations in the generated binary.
 
 OpenCL only. Allow use of less precise no signed zeros computations in the generated binary.
 
+.. option:: -cl-no-stdinc
+
+OpenCL only. Disables all standard includes containing non-native compiler types and functions.
+
 .. option:: -cl-opt-disable
 
 OpenCL only. This option disables all optimizations. By default optimizations are enabled.
@@ -2508,7 +2693,7 @@ SYCL flags
 ----------
 .. option:: -fsycl, -fno-sycl
 
-Enable SYCL kernels compilation for device
+Enables SYCL kernels compilation for device
 
 .. option:: -sycl-std=<arg>
 
@@ -2652,6 +2837,18 @@ Reserve the x9 register (AArch64/RISC-V only)
 
 .. option:: -mabi=<arg>
 
+.. program:: clang1
+.. option:: -mabi=vec-default
+.. program:: clang
+
+Enable the default Altivec ABI on AIX (AIX only). Uses only volatile vector registers.
+
+.. program:: clang2
+.. option:: -mabi=vec-extabi
+.. program:: clang
+
+Enable the extended Altivec ABI on AIX (AIX only). Uses volatile and nonvolatile vector registers
+
 .. option:: -maix-struct-return
 
 Return all structs in memory (PPC32 only)
@@ -2668,6 +2865,10 @@ Specify types of branches to align
 
 Align doubles to two words in structs (x86 only)
 
+.. option:: -mamdgpu-ieee, -mno-amdgpu-ieee
+
+Sets the IEEE bit in the expected default floating point  mode register. Floating point opcodes that support exception flag gathering quiet and propagate signaling NaN inputs per IEEE 754-2008. This option changes the ABI. (AMDGPU only)
+
 .. option:: -march=<arg>
 
 .. option:: -masm=<arg>
@@ -2684,16 +2885,16 @@ Align selected branches (fused, jcc, jmp) within 32-byte boundary
 
 .. option:: -mcode-object-v3, -mno-code-object-v3
 
-Legacy option to specify code object ABI V2 (-mnocode-object-v3) or V3 (-mcode-object-v3) (AMDGPU only)
+Legacy option to specify code object ABI V3 (AMDGPU only)
 
 .. option:: -mcode-object-version=<version>
 
-Specify code object ABI version. Defaults to 4. (AMDGPU only)
+Specify code object ABI version. Defaults to 3. (AMDGPU only)
 
 .. option:: -mconsole<arg>
 
 .. program:: clang1
-.. option:: -mcpu=<arg>, -mv5 (equivalent to -mcpu=hexagonv5), -mv55 (equivalent to -mcpu=hexagonv55), -mv60 (equivalent to -mcpu=hexagonv60), -mv62 (equivalent to -mcpu=hexagonv62), -mv65 (equivalent to -mcpu=hexagonv65), -mv66 (equivalent to -mcpu=hexagonv66), -mv67 (equivalent to -mcpu=hexagonv67), -mv67t (equivalent to -mcpu=hexagonv67t)
+.. option:: -mcpu=<arg>, -mv5 (equivalent to -mcpu=hexagonv5), -mv55 (equivalent to -mcpu=hexagonv55), -mv60 (equivalent to -mcpu=hexagonv60), -mv62 (equivalent to -mcpu=hexagonv62), -mv65 (equivalent to -mcpu=hexagonv65), -mv66 (equivalent to -mcpu=hexagonv66), -mv67 (equivalent to -mcpu=hexagonv67), -mv67t (equivalent to -mcpu=hexagonv67t), -mv68 (equivalent to -mcpu=hexagonv68)
 .. program:: clang
 
 .. option:: -mcrc, -mno-crc
@@ -2908,9 +3109,9 @@ Only supported on X86 and RISC-V. Otherwise accepted for compatibility with GCC.
 
 .. option:: -municode<arg>
 
-.. option:: -mabi=vec-extabi, -mabi=vec-default
+.. option:: -munsafe-fp-atomics, -mno-unsafe-fp-atomics
 
-Only supported on AIX. Specify usage of the extended vector ABI on AIX and of non-volatile vector registers. Defaults to '-mabi=default' when Altivec is enabled.
+Enable unsafe floating point atomic instructions (AMDGPU only)
 
 .. option:: -mvx, -mno-vx
 
@@ -2984,24 +3185,12 @@ AMDGPU
 ------
 .. option:: -mcumode, -mno-cumode
 
-Specify CU (-mcumode) or WGP (-mno-cumode) wavefront execution mode (AMDGPU only)
-
-.. option:: -msram-ecc, -mno-sram-ecc
-
-Specify SRAM ECC mode (AMDGPU only)
+Specify CU wavefront execution mode (AMDGPU only)
 
 .. option:: -mtgsplit, -mno-tgsplit
 
 Enable threadgroup split execution mode (AMDGPU only)
 
-.. option:: -mxnack, -mno-xnack
-
-Specify XNACK mode (AMDGPU only)
-
-.. option:: -munsafe-fp-atomics, -mno-unsafe-fp-atomics
-
-Enable generation of unsafe floating point atomic instructions. May generate more efficient code, but may not respect rounding and denormal modes, and may give incorrect results for certain memory destinations. (AMDGPU only)
-
 ARM
 ---
 .. option:: -faapcs-bitfield-load
@@ -3084,6 +3273,80 @@ Set Hexagon Vector Length
 
 Enable Hexagon Vector eXtensions
 
+M68k
+----
+.. option:: -ffixed-a0
+
+Reserve the a0 register (M68k only)
+
+.. option:: -ffixed-a1
+
+Reserve the a1 register (M68k only)
+
+.. option:: -ffixed-a2
+
+Reserve the a2 register (M68k only)
+
+.. option:: -ffixed-a3
+
+Reserve the a3 register (M68k only)
+
+.. option:: -ffixed-a4
+
+Reserve the a4 register (M68k only)
+
+.. option:: -ffixed-a5
+
+Reserve the a5 register (M68k only)
+
+.. option:: -ffixed-a6
+
+Reserve the a6 register (M68k only)
+
+.. option:: -ffixed-d0
+
+Reserve the d0 register (M68k only)
+
+.. option:: -ffixed-d1
+
+Reserve the d1 register (M68k only)
+
+.. option:: -ffixed-d2
+
+Reserve the d2 register (M68k only)
+
+.. option:: -ffixed-d3
+
+Reserve the d3 register (M68k only)
+
+.. option:: -ffixed-d4
+
+Reserve the d4 register (M68k only)
+
+.. option:: -ffixed-d5
+
+Reserve the d5 register (M68k only)
+
+.. option:: -ffixed-d6
+
+Reserve the d6 register (M68k only)
+
+.. option:: -ffixed-d7
+
+Reserve the d7 register (M68k only)
+
+.. option:: -m68000
+
+.. option:: -m68010
+
+.. option:: -m68020
+
+.. option:: -m68030
+
+.. option:: -m68040
+
+.. option:: -m68060
+
 MIPS
 ----
 .. option:: -mabicalls, -mno-abicalls
@@ -3202,6 +3465,12 @@ PowerPC
 
 .. option:: -mpower9-vector, -mno-power9-vector
 
+.. option:: -mprefixed, -mno-prefixed
+
+.. option:: -mprivileged
+
+.. option:: -mrop-protect
+
 .. option:: -msecure-plt
 
 .. option:: -mspe, -mno-spe
@@ -3230,8 +3499,6 @@ WebAssembly
 
 .. option:: -mtail-call, -mno-tail-call
 
-.. option:: -munimplemented-simd128, -mno-unimplemented-simd128
-
 WebAssembly Driver
 ------------------
 .. option:: -mexec-model=<arg>
@@ -3481,8 +3748,18 @@ Generate source-level debug information with dwarf version 4
 
 Generate source-level debug information with dwarf version 5
 
+.. option:: -gdwarf32
+
+Enables DWARF32 format for ELF binaries, if debug information emission is enabled.
+
+.. option:: -gdwarf64
+
+Enables DWARF64 format for ELF binaries, if debug information emission is enabled.
+
 .. option:: -gfull
 
+.. option:: -ginline-line-tables, -gno-inline-line-tables
+
 .. option:: -gused
 
 Debug level
@@ -3515,6 +3792,8 @@ Generate debug info with external references to clang modules or precompiled hea
 
 Debugger to tune debug information for
 ______________________________________
+.. option:: -gdbx
+
 .. option:: -ggdb
 
 .. option:: -glldb
@@ -3537,7 +3816,7 @@ Embed source text in DWARF debug sections
 
 .. option:: -grecord-command-line, -gno-record-command-line, -grecord-gcc-switches
 
-.. option:: -gsplit-dwarf
+.. option:: -gsplit-dwarf, -gno-split-dwarf
 
 .. program:: clang1
 .. option:: -gsplit-dwarf=<arg>
@@ -3547,8 +3826,6 @@ Set DWARF fission mode to either 'split' or 'single'
 
 .. option:: -gstrict-dwarf, -gno-strict-dwarf
 
-Restrict DWARF features to those defined in the specified version, avoiding features from later versions.
-
 .. option:: -gz=<arg>, -gz (equivalent to -gz=zlib)
 
 DWARF debug sections compression type
@@ -3572,10 +3849,6 @@ a Fortran input.
 
 .. option:: -A-<arg>
 
-.. option:: -J<arg>
-
-.. option:: -cpp
-
 .. option:: -faggressive-function-elimination, -fno-aggressive-function-elimination
 
 .. option:: -falign-commons, -fno-align-commons
@@ -3584,8 +3857,6 @@ a Fortran input.
 
 .. option:: -fautomatic, -fno-automatic
 
-.. option:: -fbackslash, -fno-backslash
-
 .. option:: -fbacktrace, -fno-backtrace
 
 .. option:: -fblas-matmul-limit=<arg>
@@ -3606,12 +3877,6 @@ a Fortran input.
 
 .. option:: -fd-lines-as-comments, -fno-d-lines-as-comments
 
-.. option:: -fdefault-double-8, -fno-default-double-8
-
-.. option:: -fdefault-integer-8, -fno-default-integer-8
-
-.. option:: -fdefault-real-8, -fno-default-real-8
-
 .. option:: -fdollar-ok, -fno-dollar-ok
 
 .. option:: -fdump-fortran-optimized, -fno-dump-fortran-optimized
@@ -3624,20 +3889,12 @@ a Fortran input.
 
 .. option:: -ff2c, -fno-f2c
 
-.. option:: -ffixed-form, -fno-fixed-form
-
-.. option:: -ffixed-line-length-<arg>
-
 .. option:: -ffpe-trap=<arg>
 
-.. option:: -ffree-form, -fno-free-form
-
 .. option:: -ffree-line-length-<arg>
 
 .. option:: -ffrontend-optimize, -fno-frontend-optimize
 
-.. option:: -fimplicit-none, -fno-implicit-none
-
 .. option:: -finit-character=<arg>
 
 .. option:: -finit-integer=<arg>
@@ -3650,8 +3907,6 @@ a Fortran input.
 
 .. option:: -finteger-4-integer-8, -fno-integer-4-integer-8
 
-.. option:: -fintrinsic-modules-path, -fno-intrinsic-modules-path
-
 .. option:: -fmax-array-constructor=<arg>
 
 .. option:: -fmax-errors=<arg>
@@ -3702,8 +3957,6 @@ a Fortran input.
 
 .. option:: -imultilib <arg>
 
-.. option:: -nocpp
-
 .. option:: -static-libgfortran
 
 Linker flags
@@ -3801,3 +4054,4 @@ undef all system defines
 .. option:: -z <arg>
 
 Pass -z <arg> to the linker
+

diff  --git a/clang/include/clang/Driver/ClangOptionDocs.td b/clang/include/clang/Driver/ClangOptionDocs.td
index 55136421614d8..3f914afea735a 100644
--- a/clang/include/clang/Driver/ClangOptionDocs.td
+++ b/clang/include/clang/Driver/ClangOptionDocs.td
@@ -29,7 +29,7 @@ GCC-compatible ``clang`` and ``clang++`` drivers.
 
   string Program = "clang";
   list<string> ExcludedFlags = ["HelpHidden", "NoDriverOption",
-                                "CLOption", "Unsupported", "Ignored"];
+                                "CLOption", "Unsupported", "Ignored", "FlangOnlyOption"];
 }
 
 include "Options.td"


        


More information about the cfe-commits mailing list