This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

gcc/invoke.texi: Add missing @opindex


While looking at the index for -fsanitize=, I found out that it â and many other options â lack the @opindex. Attached is an attempted to add the missing ones.

OK?

Tobias
diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi
index 0708836..b41c44c 100644
--- a/gcc/doc/invoke.texi
+++ b/gcc/doc/invoke.texi
@@ -1500,6 +1500,7 @@ This invokes all subprograms of @command{gcc} under
 @samp{gdb --args cc1 @dots{}}.
 
 @item -fplugin=@var{name}.so
+@opindex fplugin
 Load the plugin code in file @var{name}.so, assumed to be a
 shared object to be dlopen'd by the compiler.  The base name of
 the shared object file is used to identify the plugin for the
@@ -1509,15 +1510,18 @@ Each plugin should define the callback functions specified in the
 Plugins API.
 
 @item -fplugin-arg-@var{name}-@var{key}=@var{value}
+@opindex fplugin-arg
 Define an argument called @var{key} with a value of @var{value}
 for the plugin called @var{name}.
 
 @item -fdump-ada-spec@r{[}-slim@r{]}
+@opindex fdump-ada-spec
 For C and C++ source and include files, generate corresponding Ada
 specs. @xref{Generating Ada Bindings for C and C++ headers,,, gnat_ugn,
 GNAT User's Guide}, which provides detailed documentation on this feature.
 
 @item -fdump-go-spec=@var{file}
+@opindex fdump-go-spec
 For input files in any language, generate corresponding Go
 declarations in @var{file}.  This generates Go @code{const},
 @code{type}, @code{var}, and @code{func} declarations which may be a
@@ -1751,6 +1755,7 @@ arguments followed by their declarations is also provided, inside
 comments, after the declaration.
 
 @item -fallow-parameterless-variadic-functions
+@opindex fallow-parameterless-variadic-functions
 Accept variadic functions without named parameters.
 
 Although it is possible to define such a function, this is not very
@@ -2392,7 +2397,7 @@ Note:  This feature APPENDS data to the log file. If you want a fresh log
 file, be sure to delete any existing one.
 
 @item -fvtv-counts
-@opindex (fvtv-counts)
+@opindex fvtv-counts
 This is a debugging flag.  When used in conjunction with
 @option{-fvtable-verify=std} or @option{-fvtable-verify=preinit}, this
 causes the compiler to keep track of the total number of virtual calls
@@ -3490,6 +3495,8 @@ Options,,Options Controlling C Dialect}.
 @table @gcctabopt
 @item -Wformat=1
 @itemx -Wformat
+@opindex Wformat
+@opindex Wformat=1
 Option @option{-Wformat} is equivalent to @option{-Wformat=1}, and
 @option{-Wno-format} is equivalent to @option{-Wformat=0}.  Since
 @option{-Wformat} also checks for null format arguments for several
@@ -3528,6 +3535,7 @@ The C standard specifies that zero-length formats are allowed.
 
 
 @item -Wformat=2
+@opindex Wformat=2
 Enable @option{-Wformat} plus additional format checks.  Currently
 equivalent to @option{-Wformat -Wformat-nonliteral -Wformat-security
 -Wformat-y2k}.
@@ -5258,18 +5266,21 @@ many times it is given.  This is mainly intended to be used with
 @option{-fcompare-debug}.
 
 @item -fsanitize=address
+@opindex fsanitize=
 Enable AddressSanitizer, a fast memory error detector.
 Memory access instructions will be instrumented to detect
 out-of-bounds and use-after-free bugs.
 See @uref{http://code.google.com/p/address-sanitizer/} for more details.
 
 @item -fsanitize=thread
+@opindex fsanitize=thread
 Enable ThreadSanitizer, a fast data race detector.
 Memory access instructions will be instrumented to detect
 data race bugs.
 See @uref{http://code.google.com/p/data-race-test/wiki/ThreadSanitizer} for more details.
 
 @item -fsanitize=leak
+@opindex fsanitize=leak
 Enable LeakSanitizer, a memory leak detector.
 This option only matters for linking of executables and if neither
 @option{-fsanitize=address} nor @option{-fsanitize=thread} is used.  In that
@@ -5277,6 +5288,7 @@ case it will link the executable against a library that overrides @code{malloc}
 and other allocator functions.
 
 @item -fsanitize=undefined
+@opindex fsanitize=undefined
 Enable UndefinedBehaviorSanitizer, a fast undefined behavior detector.
 Various computations will be instrumented to detect undefined behavior
 at runtime.  Current suboptions are:
@@ -5284,22 +5296,26 @@ at runtime.  Current suboptions are:
 @itemize @bullet
 
 @item @option{-fsanitize=shift}
+@opindex fsanitize=shift
 
 This option enables checking that the result of a shift operation is
 not undefined.  Note that what exactly is considered undefined differs
 slightly between C and C++, as well as between ISO C90 and C99, etc.
 
 @item @option{-fsanitize=integer-divide-by-zero}
+@opindex fsanitize=integer-divide-by-zero
 
 Detect integer division by zero as well as @code{INT_MIN / -1} division.
 
 @item @option{-fsanitize=unreachable}
+@opindex fsanitize=unreachable
 
 With this option, the compiler will turn the @code{__builtin_unreachable}
 call into a diagnostics message call instead.  When reaching the
 @code{__builtin_unreachable} call, the behavior is undefined.
 
 @item @option{-fsanitize=vla-bound}
+@opindex fsanitize=vla-bound
 
 This option instructs the compiler to check that the size of a variable
 length array is positive.  This option does not have any effect in
@@ -5307,6 +5323,7 @@ length array is positive.  This option does not have any effect in
 instead.
 
 @item @option{-fsanitize=null}
+@opindex fsanitize=null
 
 This option enables pointer checking.  Particularly, the application
 built with this option turned on will issue an error message when it
@@ -5375,6 +5392,7 @@ information about each symbol.  This option only makes sense when
 generating DWARF 2 debugging information with @option{-gdwarf-2}.
 
 @item -femit-struct-debug-baseonly
+@opindex femit-struct-debug-baseonly
 Emit debug information for struct-like types
 only when the base name of the compilation source file
 matches the base name of file in which the struct is defined.
@@ -5387,6 +5405,7 @@ See @option{-femit-struct-debug-detailed} for more detailed control.
 This option works only with DWARF 2.
 
 @item -femit-struct-debug-reduced
+@opindex femit-struct-debug-reduced
 Emit debug information for struct-like types
 only when the base name of the compilation source file
 matches the base name of file in which the type is defined,
@@ -5653,12 +5672,14 @@ passes instead.
 @table @gcctabopt
 
 @item -fdisable-ipa-@var{pass}
+@opindex fdisable-ipa-@var{pass}
 Disable IPA pass @var{pass}. @var{pass} is the pass name.  If the same pass is
 statically invoked in the compiler multiple times, the pass name should be
 appended with a sequential number starting from 1.
 
 @item -fdisable-rtl-@var{pass}
 @itemx -fdisable-rtl-@var{pass}=@var{range-list}
+@opindex fdisable-rtl-@var{pass}
 Disable RTL pass @var{pass}.  @var{pass} is the pass name.  If the same pass is
 statically invoked in the compiler multiple times, the pass name should be
 appended with a sequential number starting from 1.  @var{range-list} is a 
@@ -5672,21 +5693,25 @@ option @option{-fdump-passes}.
 
 @item -fdisable-tree-@var{pass}
 @itemx -fdisable-tree-@var{pass}=@var{range-list}
+@opindex fdisable-tree-@var{pass}
 Disable tree pass @var{pass}.  See @option{-fdisable-rtl} for the description of
 option arguments.
 
 @item -fenable-ipa-@var{pass}
+@opindex fenable-ipa-@var{pass}
 Enable IPA pass @var{pass}.  @var{pass} is the pass name.  If the same pass is
 statically invoked in the compiler multiple times, the pass name should be
 appended with a sequential number starting from 1.
 
 @item -fenable-rtl-@var{pass}
 @itemx -fenable-rtl-@var{pass}=@var{range-list}
+@opindex fenable-rtl-@var{pass}
 Enable RTL pass @var{pass}.  See @option{-fdisable-rtl} for option argument
 description and examples.
 
 @item -fenable-tree-@var{pass}
 @itemx -fenable-tree-@var{pass}=@var{range-list}
+@opindex fenable-tree-@var{pass}
 Enable tree pass @var{pass}.  See @option{-fdisable-rtl} for the description
 of option arguments.
 
@@ -5717,6 +5742,7 @@ Here are some examples showing uses of these options.
 @itemx -fdump-rtl-@var{pass}
 @itemx -fdump-rtl-@var{pass}=@var{filename}
 @opindex d
+@opindex fdump-rtl-@var{pass}
 Says to make debugging dumps during compilation at times specified by
 @var{letters}.  This is used for debugging the RTL-based passes of the
 compiler.  The file names for most of the dumps are made by appending
@@ -8005,6 +8031,7 @@ variable names which more closely resemble the original variables.  This flag
 is enabled by default at @option{-O} and higher.
 
 @item -ftree-coalesce-inlined-vars
+@opindex ftree-coalesce-inlined-vars
 Tell the copyrename pass (see @option{-ftree-copyrename}) to attempt to
 combine small user-defined variables too, but only if they were inlined
 from other functions.  It is a more limited form of
@@ -8015,6 +8042,7 @@ contain the expected values in a debugging session.  This was the
 default in GCC versions older than 4.7.
 
 @item -ftree-coalesce-vars
+@opindex ftree-coalesce-vars
 Tell the copyrename pass (see @option{-ftree-copyrename}) to attempt to
 combine small user-defined variables too, instead of just compiler
 temporaries.  This may severely limit the ability to debug an optimized
@@ -8658,9 +8686,11 @@ the comparison operation before register allocation is complete.
 Enabled at levels @option{-O}, @option{-O2}, @option{-O3}, @option{-Os}.
 
 @item -fuse-ld=bfd
+@opindex fuse-ld=bfd
 Use the @command{bfd} linker instead of the default linker.
 
 @item -fuse-ld=gold
+@opindex fuse-ld=gold
 Use the @command{gold} linker instead of the default linker.
 
 @item -fcprop-registers
@@ -10217,6 +10247,7 @@ for the languages used in the program, or using the option
 @file{libgcc}.
 
 @item -static-libasan
+@opindex static-libasan
 When the @option{-fsanitize=address} option is used to link a program,
 the GCC driver automatically links against @option{libasan}.  If
 @file{libasan} is available as a shared library, and the @option{-static}
@@ -10226,6 +10257,7 @@ driver to link @file{libasan} statically, without necessarily linking
 other libraries statically.
 
 @item -static-libtsan
+@opindex static-libtsan
 When the @option{-fsanitize=thread} option is used to link a program,
 the GCC driver automatically links against @option{libtsan}.  If
 @file{libtsan} is available as a shared library, and the @option{-static}
@@ -10235,6 +10267,7 @@ driver to link @file{libtsan} statically, without necessarily linking
 other libraries statically.
 
 @item -static-liblsan
+@opindex static-liblsan
 When the @option{-fsanitize=leak} option is used to link a program,
 the GCC driver automatically links against @option{liblsan}.  If
 @file{liblsan} is available as a shared library, and the @option{-static}
@@ -10244,6 +10277,7 @@ driver to link @file{liblsan} statically, without necessarily linking
 other libraries statically.
 
 @item -static-libubsan
+@opindex static-libubsan
 When the @option{-fsanitize=undefined} option is used to link a program,
 the GCC driver automatically links against @option{libubsan}.  If
 @file{libubsan} is available as a shared library, and the @option{-static}
@@ -10253,6 +10287,7 @@ driver to link @file{libubsan} statically, without necessarily linking
 other libraries statically.
 
 @item -static-libstdc++
+@opindex static-libstdc++
 When the @command{g++} program is used to link a C++ program, it
 normally automatically links against @option{libstdc++}.  If
 @file{libstdc++} is available as a shared library, and the
@@ -10345,6 +10380,7 @@ If you really need to change the search order for system directories,
 use the @option{-nostdinc} and/or @option{-isystem} options.
 
 @item -iplugindir=@var{dir}
+@opindex iplugindir=
 Set the directory to search for plugins that are passed
 by @option{-fplugin=@var{name}} instead of
 @option{-fplugin=@var{path}/@var{name}.so}.  This option is not meant
@@ -11794,7 +11830,7 @@ Enable Rcw constraint handling - ccfsm condexec mostly depends on this.
 This is the default.
 
 @item -msize-level=@var{level}
-@ opindex msize-level
+@opindex msize-level
 Fine-tune size optimization with regards to instruction lengths and alignment.
 The recognized values for @var{level} are:
 @table @samp

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]