https://gcc.gnu.org/g:d0ce13e26cab65735bb99f0a61c1ff25979eb0ba

commit r16-7024-gd0ce13e26cab65735bb99f0a61c1ff25979eb0ba
Author: Sandra Loosemore <[email protected]>
Date:   Sun Jan 25 00:40:51 2026 +0000

    doc: Mark more options as Undocumented/RejectNegative [PR122243]
    
    In reviewing the autogenerated list of remaining undocumented options
    after my first pass through the whole chapter, I found several more
    options I'd previously overlooked that should either be marked
    Undocumented, or that were missing a RejectNegative attribute where
    one was plainly appropriate.
    
    gcc/c-family/ChangeLog
            PR other/122243
            * c.opt (-output-pch): Mark as Undocumented, as it seems to be
            an internal option that has never been documented anyway.
            (Werror-implicit-function-declaration): Mark deprecated option
            that is not currently documented as Undocumented.
            (fconstant-string-class=): Add RejectNegative property.
    
    gcc/ChangeLog
            PR other/122243
            * common.opt (fbounds-check): Mark as Undocumented, expand comments
            to explain why.
            * config/frv/frv.opt (msched-lookahead=): Mark unused option as
            Undocumented.
            * config/m68k/m68k.opt (m68851): Add RejectNegative.
            * config/nvptx/nvptx.opt (minit-regs=): Mark as Undocumented.  It's
            not currently documented and seems to have been introduced as a
            stopgap to experiment with different implementation strategies.
            * config/rs6000/476.opt (mpreserve-link-stack): Mark as 
Undocumented.
            It seems to be an internal option that is enabled by default on the
            cpu that can benefit from it.

Diff:
---
 gcc/c-family/c.opt         | 8 +++++---
 gcc/common.opt             | 7 ++++---
 gcc/config/frv/frv.opt     | 3 ++-
 gcc/config/m68k/m68k.opt   | 2 +-
 gcc/config/nvptx/nvptx.opt | 2 +-
 gcc/config/rs6000/476.opt  | 2 +-
 6 files changed, 14 insertions(+), 10 deletions(-)

diff --git a/gcc/c-family/c.opt b/gcc/c-family/c.opt
index e286c3b0535b..a4065d685586 100644
--- a/gcc/c-family/c.opt
+++ b/gcc/c-family/c.opt
@@ -149,8 +149,10 @@ C ObjC C++ ObjC++ Separate Alias(o)
 -output=
 C ObjC C++ ObjC++ Joined Alias(o)
 
+; The documented user option for PCH output is -o.  The driver converts that
+; to -output-pch when invoking the front ends to produce a PCH file.
 -output-pch
-C ObjC C++ ObjC++ Separate
+C ObjC C++ ObjC++ Separate Undocumented
 
 -pedantic
 C ObjC C++ ObjC++ Alias(pedantic)
@@ -758,7 +760,7 @@ C ObjC C++ ObjC++
 ; Documented in common.opt
 
 Werror-implicit-function-declaration
-C ObjC RejectNegative Warning Alias(Werror=, implicit-function-declaration)
+C ObjC RejectNegative Undocumented Warning Alias(Werror=, 
implicit-function-declaration)
 This switch is deprecated; use -Werror=implicit-function-declaration instead.
 
 Wexceptions
@@ -1875,7 +1877,7 @@ C++ ObjC++ Ignore
 Does nothing.  Preserved for backward compatibility.
 
 fconstant-string-class=
-ObjC ObjC++ Joined MissingArgError(no class name specified with %qs)
+ObjC ObjC++ Joined RejectNegative MissingArgError(no class name specified with 
%qs)
 -fconst-string-class=<name>    Use class <name> for constant strings.
 
 fconstexpr-depth=
diff --git a/gcc/common.opt b/gcc/common.opt
index 59b8efe54146..4c73f51defac 100644
--- a/gcc/common.opt
+++ b/gcc/common.opt
@@ -1213,10 +1213,11 @@ Common Var(flag_auto_profile_inlining) Init(1) 
Optimization
 Perform inlining using auto-profile.
 
 ; -fbounds-check causes gcc to generate array bounds checks.
-; It's presently used only for fortran and d languages, and is documented
-; in the manuals for those languages.
+; It's presently used only for fortran, algol68, and d languages.
+; In Fortran and algol68 it is a deprecated alias for -fcheck=bounds,
+; in D it is documented in the D language manual.
 fbounds-check
-Common Var(flag_bounds_check)
+Common Undocumented Var(flag_bounds_check)
 Generate code to check bounds before indexing arrays.
 
 fbranch-count-reg
diff --git a/gcc/config/frv/frv.opt b/gcc/config/frv/frv.opt
index b9771a897fad..27e881d96a56 100644
--- a/gcc/config/frv/frv.opt
+++ b/gcc/config/frv/frv.opt
@@ -206,8 +206,9 @@ mscc
 Target Mask(SCC)
 Enable setting GPRs to the result of comparisons.
 
+; This option seems not to be used anywhere.
 msched-lookahead=
-Target RejectNegative Joined UInteger Var(frv_sched_lookahead) Init(4)
+Target Undocumented RejectNegative Joined UInteger Var(frv_sched_lookahead) 
Init(4)
 Change the amount of scheduler lookahead.
 
 msoft-float
diff --git a/gcc/config/m68k/m68k.opt b/gcc/config/m68k/m68k.opt
index a97fac654d88..7558ce1b9c7a 100644
--- a/gcc/config/m68k/m68k.opt
+++ b/gcc/config/m68k/m68k.opt
@@ -87,7 +87,7 @@ Generate code for a 68332.
 
 ; Has no effect on gcc
 m68851
-Target
+Target RejectNegative
 Generate code for a 68851.
 
 m68881
diff --git a/gcc/config/nvptx/nvptx.opt b/gcc/config/nvptx/nvptx.opt
index 62a4fa464552..c3b128d3e04d 100644
--- a/gcc/config/nvptx/nvptx.opt
+++ b/gcc/config/nvptx/nvptx.opt
@@ -204,7 +204,7 @@ Target RejectNegative Negative(mptx=) ToLower Joined 
Enum(ptx_version) Var(ptx_v
 Specify the PTX ISA version to use.
 
 minit-regs=
-Target Var(nvptx_init_regs) IntegerRange(0, 3) Joined UInteger Init(3)
+Target Undocumented Var(nvptx_init_regs) IntegerRange(0, 3) Joined UInteger 
Init(3)
 Initialize ptx registers.
 
 mptx-comment
diff --git a/gcc/config/rs6000/476.opt b/gcc/config/rs6000/476.opt
index ac3de91ff5b5..43230a1466e2 100644
--- a/gcc/config/rs6000/476.opt
+++ b/gcc/config/rs6000/476.opt
@@ -20,5 +20,5 @@
 ; <http://www.gnu.org/licenses/>.
 
 mpreserve-link-stack
-Target Var(rs6000_link_stack) Init(-1) Save
+Target Undocumented Var(rs6000_link_stack) Init(-1) Save
 Preserve the PowerPC 476's link stack by matching up a blr with the bcl/bl 
insns used for GOT accesses.

Reply via email to