Limit dump_flag enum values range (PR middle-end/86645).
authorMartin Liska <mliska@suse.cz>
Wed, 25 Jul 2018 08:04:15 +0000 (10:04 +0200)
committerMartin Liska <marxin@gcc.gnu.org>
Wed, 25 Jul 2018 08:04:15 +0000 (08:04 +0000)
2018-07-25  Martin Liska  <mliska@suse.cz>

        PR middle-end/86645
* dumpfile.c: And excluded values with TDF_ALL_VALUES.
* dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.

From-SVN: r262960

gcc/ChangeLog
gcc/dumpfile.c
gcc/dumpfile.h

index fcbaefef6a49c9a491dd5540e7a5c1bb87eb85e5..3a2780455de69cbe3c4d6416e5ef16f2af57de4c 100644 (file)
@@ -1,3 +1,9 @@
+2018-07-25  Martin Liska  <mliska@suse.cz>
+
+        PR middle-end/86645
+       * dumpfile.c: And excluded values with TDF_ALL_VALUES.
+       * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
+
 2018-07-25  Martin Liska  <mliska@suse.cz>
 
         PR sanitizer/79635
index 6c9920c6bd2ffb02297cc15754f2055fcc2bef1e..176c9b846d7dc5ebbbdb1a88753b1fac663443e6 100644 (file)
@@ -150,9 +150,10 @@ static const kv_pair<dump_flags_t> dump_options[] =
   {"missed", MSG_MISSED_OPTIMIZATION},
   {"note", MSG_NOTE},
   {"optall", MSG_ALL},
-  {"all", dump_flags_t (~(TDF_RAW | TDF_SLIM | TDF_LINENO | TDF_GRAPH
-                       | TDF_STMTADDR | TDF_RHS_ONLY | TDF_NOUID
-                       | TDF_ENUMERATE_LOCALS | TDF_SCEV | TDF_GIMPLE))},
+  {"all", dump_flags_t (TDF_ALL_VALUES
+                       & ~(TDF_RAW | TDF_SLIM | TDF_LINENO | TDF_GRAPH
+                           | TDF_STMTADDR | TDF_RHS_ONLY | TDF_NOUID
+                           | TDF_ENUMERATE_LOCALS | TDF_SCEV | TDF_GIMPLE))},
   {NULL, TDF_NONE}
 };
 
index ad14acdfc9abe179139170a08079b0e949e039d5..1dbe3b85b7c973f0e568fd6b74a5bd2f733f5594 100644 (file)
@@ -146,7 +146,10 @@ enum dump_flag
             | MSG_NOTE),
 
   /* Dumping for -fcompare-debug.  */
-  TDF_COMPARE_DEBUG = (1 << 25)
+  TDF_COMPARE_DEBUG = (1 << 25),
+
+  /* All values.  */
+  TDF_ALL_VALUES = (1 << 26) - 1
 };
 
 /* Dump flags type.  */