]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
dwarf2out.c (gen_producer_string): Omit command line switch if CL_NO_DWARF_RECORD...
authorSimon Baldwin <simonb@google.com>
Fri, 24 Aug 2012 14:58:06 +0000 (14:58 +0000)
committerSimon Baldwin <simonb@gcc.gnu.org>
Fri, 24 Aug 2012 14:58:06 +0000 (14:58 +0000)
gcc/ChangeLog
* dwarf2out.c (gen_producer_string): Omit command line switch if
CL_NO_DWARF_RECORD flag set.
* opts.h (CL_NO_DWARF_RECORD): New.
* opt-functions.awk (switch_flags): Add NoDWARFRecord.
* doc/options.texi: Document NoDWARFRecord option flag.

gcc/fortran/ChangeLog
* lang.opt (-cpp=): Mark flag NoDWARFRecord.

From-SVN: r190648

gcc/ChangeLog
gcc/doc/options.texi
gcc/dwarf2out.c
gcc/fortran/ChangeLog
gcc/fortran/lang.opt
gcc/opt-functions.awk
gcc/opts.h

index 65cb9939d9be0c8f03b8b970f9431d4f4cf5d8b9..9569688ba10852c911cdc9d308f039a1c6698ee0 100644 (file)
@@ -1,3 +1,11 @@
+2012-08-24  Simon Baldwin  <simonb@google.com>
+
+       * dwarf2out.c (gen_producer_string): Omit command line switch if
+       CL_NO_DWARF_RECORD flag set.
+       * opts.h (CL_NO_DWARF_RECORD): New.
+       * opt-functions.awk (switch_flags): Add NoDWARFRecord.
+       * doc/options.texi: Document NoDWARFRecord option flag.
+
 2012-08-24  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR debug/52857
index ef720307eee60fad902042893987a09019aa6be2..9c004c8cd3f8fadfadc936ef77c6ba83bc816d35 100644 (file)
@@ -468,4 +468,8 @@ of @option{-@var{opt}}, if not explicitly set. It is possible to
 specify several different languages.  Each @var{language} must have
 been declared by an earlier @code{Language} record.  @xref{Option file
 format}.
+
+@item NoDWARFRecord
+The option is omitted from the producer string written by
+@option{-grecord-gcc-switches}.
 @end table
index 4c268d48eeaa1ba4944bb776ff7d0d138b0c8727..a87eaf2bd7dd4f59ea937846476075d2d480ce64 100644 (file)
@@ -18142,6 +18142,9 @@ gen_producer_string (void)
        /* Ignore these.  */
        continue;
       default:
+        if (cl_options[save_decoded_options[j].opt_index].flags
+           & CL_NO_DWARF_RECORD)
+         continue;
         gcc_checking_assert (save_decoded_options[j].canonical_option[0][0]
                             == '-');
         switch (save_decoded_options[j].canonical_option[0][1])
index e8b4b4168bd9f7702a86023730feb8426697f9f5..f67e501f4200408aa88eeaaefe211ccf913a6580 100644 (file)
@@ -1,3 +1,7 @@
+2012-08-24  Simon Baldwin  <simonb@google.com>
+
+       * lang.opt (-cpp=): Mark flag NoDWARFRecord.
+
 2012-08-23  Tobias Burnus  <burnus@net-b.de>
 
        PR fortran/54350
index b38b1e8bea19d47b1e97f1b2642374d01decf4f7..8a633464c4c63a903e0aaffdb24106ae6b7bbd64 100644 (file)
@@ -295,7 +295,7 @@ Fortran Negative(nocpp)
 Enable preprocessing
 
 cpp=
-Fortran Joined Negative(nocpp) Undocumented
+Fortran Joined Negative(nocpp) Undocumented NoDWARFRecord
 ; Internal option generated by specs from -cpp.
 
 nocpp
index 8e098c28c2ccebb6c1982254f12a718efbdcba94..8b025b2cf32f428198bacc6be228a088d0f18075 100644 (file)
@@ -103,6 +103,7 @@ function switch_flags (flags)
          test_flag("JoinedOrMissing", flags, " | CL_JOINED") \
          test_flag("Separate", flags, " | CL_SEPARATE") \
          test_flag("Undocumented", flags,  " | CL_UNDOCUMENTED") \
+         test_flag("NoDWARFRecord", flags,  " | CL_NO_DWARF_RECORD") \
          test_flag("Warning", flags,  " | CL_WARNING") \
          test_flag("Optimization", flags,  " | CL_OPTIMIZATION")
        sub( "^0 \\| ", "", result )
index dbefc6401d9288b277ca08e42f05a15376eb8887..a9336af74bcb657e7d834ab554cb2caedb4ea16e 100644 (file)
@@ -145,6 +145,7 @@ extern const unsigned int cl_lang_count;
 #define CL_JOINED              (1U << 22) /* If takes joined argument.  */
 #define CL_SEPARATE            (1U << 23) /* If takes a separate argument.  */
 #define CL_UNDOCUMENTED                (1U << 24) /* Do not output with --help.  */
+#define CL_NO_DWARF_RECORD     (1U << 25) /* Do not add to producer string.  */
 
 /* Flags for an enumerated option argument.  */
 #define CL_ENUM_CANONICAL      (1 << 0) /* Canonical for this value.  */