[gcc(refs/users/marxin/heads/marxin-gcc-benchmark-branch)] Do not print params in --help except --help=param.

Martin Liska marxin@gcc.gnu.org
Mon Mar 30 10:30:06 GMT 2020


https://gcc.gnu.org/g:10fe5cbe0047478b030c13c8537ef5bc752a2048

commit 10fe5cbe0047478b030c13c8537ef5bc752a2048
Author: Martin Liska <mliska@suse.cz>
Date:   Mon Jan 27 11:00:53 2020 +0100

    Do not print params in --help except --help=param.
    
            * opts.c (print_help): Exclude params from
            all except --help=param.

Diff:
---
 gcc/ChangeLog | 5 +++++
 gcc/opts.c    | 4 +++-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 59806baa757..4fc5dcd527e 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2020-01-27  Martin Liska  <mliska@suse.cz>
+
+	* opts.c (print_help): Exclude params from
+	all except --help=param.
+
 2020-01-27  Martin Liska  <mliska@suse.cz>
 
 	PR target/93274
diff --git a/gcc/opts.c b/gcc/opts.c
index 33a662b54f5..3b2cc854af1 100644
--- a/gcc/opts.c
+++ b/gcc/opts.c
@@ -2140,7 +2140,9 @@ print_help (struct gcc_options *opts, unsigned int lang_mask,
   /* We started using PerFunction/Optimization for parameters and
      a warning.  We should exclude these from optimization options.  */
   if (include_flags & CL_OPTIMIZATION)
-    exclude_flags |= CL_WARNING | CL_PARAMS;
+    exclude_flags |= CL_WARNING;
+  if (!(include_flags & CL_PARAMS))
+    exclude_flags |= CL_PARAMS;
 
   if (include_flags)
     print_specific_help (include_flags, exclude_flags, 0, opts,


More information about the Gcc-cvs mailing list