summaryrefslogtreecommitdiff
path: root/gcc/dumpfile.h
diff options
context:
space:
mode:
authorMartin Liska <mliska@suse.cz>2017-05-17 11:01:36 +0200
committerMartin Liska <marxin@gcc.gnu.org>2017-05-17 09:01:36 +0000
commit1a81741814618bc19d13de0b9e59c0324114cc86 (patch)
tree10c3b673319b0cdfae3db0314371cb6732181161 /gcc/dumpfile.h
parentb2fa0a8bdfe15c427f5750f008509ed518683e2b (diff)
Introduce dump_flags_t type and use it instead of int type.
2017-05-17 Martin Liska <mliska@suse.cz> * class.c (dump_class_hierarchy): Introduce dump_flags_t type and use it instead of int type. (dump_vtable): Likewise. (dump_vtt): Likewise. * decl2.c (dump_tu): Likewise. 2017-05-17 Martin Liska <mliska@suse.cz> * c-common.h: Introduce dump_flags_t type and use it instead of int type. * c-gimplify.c (c_genericize): Likewise. * c-opts.c: Likewise. 2017-05-17 Martin Liska <mliska@suse.cz> * c-decl.c (c_parse_final_cleanups): Introduce dump_flags_t type and use it instead of int type. 2017-05-17 Martin Liska <mliska@suse.cz> * cfg.c: Introduce dump_flags_t type and use it instead of int type. * cfg.h: Likewise. * cfghooks.c: Likewise. * cfghooks.h (struct cfg_hooks): Likewise. * cfgrtl.c: Likewise. * cfgrtl.h: Likewise. * cgraph.c (cgraph_node::get_body): Likewise. * coretypes.h: Likewise. * domwalk.c: Likewise. * domwalk.h: Likewise. * dumpfile.c (struct dump_option_value_info): Likewise. (dump_enable_all): Likewise. (dump_switch_p_1): Likewise. (opt_info_switch_p): Likewise. * dumpfile.h (enum tree_dump_index): Likewise. (struct dump_file_info): Likewise. * genemit.c: Likewise. * generic-match-head.c: Likewise. * gengtype.c (open_base_files): Likewise. * gimple-pretty-print.c: Likewise. * gimple-pretty-print.h: Likewise. * graph.c (print_graph_cfg): Likewise. * graphite-scop-detection.c (dot_all_sese): Likewise. * ipa-devirt.c (build_type_inheritance_graph): Likewise. * loop-unroll.c (report_unroll): Likewise. * passes.c (pass_manager::register_one_dump_file): Likewise. * print-tree.c: Likewise. * statistics.c: Likewise. * tree-cfg.c: Likewise. * tree-cfg.h: Likewise. * tree-dfa.c: Likewise. * tree-dfa.h: Likewise. * tree-dump.c (dump_function): Likewise. * tree-dump.h (struct dump_info): Likewise. * tree-pretty-print.c: Likewise. * tree-pretty-print.h: Likewise. * tree-ssa-live.c: Likewise. * tree-ssa-live.h: Likewise. * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Likewise. * tree-vect-loop.c: Likewise. * tree-vect-slp.c: Likewise. From-SVN: r248140
Diffstat (limited to 'gcc/dumpfile.h')
-rw-r--r--gcc/dumpfile.h42
1 files changed, 26 insertions, 16 deletions
diff --git a/gcc/dumpfile.h b/gcc/dumpfile.h
index 19c6d3ec90e..92920968db1 100644
--- a/gcc/dumpfile.h
+++ b/gcc/dumpfile.h
@@ -99,6 +99,10 @@ enum tree_dump_index
| MSG_NOTE)
+/* Value of TDF_NONE is used just for bits filtered by TDF_KIND_MASK. */
+
+#define TDF_NONE 0
+
/* Flags to control high-level -fopt-info dumps. Usually these flags
define a group of passes. An optimization pass can be part of
multiple groups. */
@@ -113,6 +117,10 @@ enum tree_dump_index
#define OPTGROUP_ALL (OPTGROUP_IPA | OPTGROUP_LOOP | OPTGROUP_INLINE \
| OPTGROUP_OMP | OPTGROUP_VEC | OPTGROUP_OTHER)
+/* Dump flags type. */
+
+typedef uint64_t dump_flags_t;
+
/* Define a tree dump switch. */
struct dump_file_info
{
@@ -123,7 +131,7 @@ struct dump_file_info
const char *alt_filename; /* filename for the -fopt-info stream */
FILE *pstream; /* pass-specific dump stream */
FILE *alt_stream; /* -fopt-info stream */
- int pflags; /* dump flags */
+ dump_flags_t pflags; /* dump flags */
int optgroup_flags; /* optgroup flags for -fopt-info */
int alt_flags; /* flags for opt-info */
int pstate; /* state of pass-specific stream */
@@ -140,34 +148,35 @@ struct dump_file_info
};
/* In dumpfile.c */
-extern FILE *dump_begin (int, int *);
+extern FILE *dump_begin (int, dump_flags_t *);
extern void dump_end (int, FILE *);
extern int opt_info_switch_p (const char *);
extern const char *dump_flag_name (int);
-extern void dump_printf (int, const char *, ...) ATTRIBUTE_PRINTF_2;
-extern void dump_printf_loc (int, source_location,
- const char *, ...) ATTRIBUTE_PRINTF_3;
+extern void dump_printf (dump_flags_t, const char *, ...) ATTRIBUTE_PRINTF_2;
+extern void dump_printf_loc (dump_flags_t, source_location,
+ const char *, ...) ATTRIBUTE_PRINTF_3;
extern void dump_function (int phase, tree fn);
extern void dump_basic_block (int, basic_block, int);
extern void dump_generic_expr_loc (int, source_location, int, tree);
-extern void dump_generic_expr (int, int, tree);
-extern void dump_gimple_stmt_loc (int, source_location, int, gimple *, int);
-extern void dump_gimple_stmt (int, int, gimple *, int);
+extern void dump_generic_expr (dump_flags_t, dump_flags_t, tree);
+extern void dump_gimple_stmt_loc (dump_flags_t, source_location, dump_flags_t,
+ gimple *, int);
+extern void dump_gimple_stmt (dump_flags_t, dump_flags_t, gimple *, int);
extern void print_combine_total_stats (void);
extern bool enable_rtl_dump_file (void);
/* In tree-dump.c */
-extern void dump_node (const_tree, int, FILE *);
+extern void dump_node (const_tree, dump_flags_t, FILE *);
/* In combine.c */
extern void dump_combine_total_stats (FILE *);
/* In cfghooks.c */
-extern void dump_bb (FILE *, basic_block, int, int);
+extern void dump_bb (FILE *, basic_block, int, dump_flags_t);
/* Global variables used to communicate with passes. */
extern FILE *dump_file;
extern FILE *alt_dump_file;
-extern int dump_flags;
+extern dump_flags_t dump_flags;
extern const char *dump_file_name;
/* Return true if any of the dumps is enabled, false otherwise. */
@@ -192,7 +201,7 @@ public:
SUFFIX, SWTCH, and GLOB. */
unsigned int
dump_register (const char *suffix, const char *swtch, const char *glob,
- int flags, int optgroup_flags,
+ dump_flags_t flags, int optgroup_flags,
bool take_ownership);
/* Return the dump_file_info for the given phase. */
@@ -219,7 +228,7 @@ public:
set dump_flags appropriately for both pass dump stream and
-fopt-info stream. */
int
- dump_start (int phase, int *flag_ptr);
+ dump_start (int phase, dump_flags_t *flag_ptr);
/* Finish a tree dump for PHASE and close associated dump streams. Also
reset the globals DUMP_FILE, ALT_DUMP_FILE, and DUMP_FLAGS. */
@@ -227,7 +236,7 @@ public:
dump_finish (int phase);
FILE *
- dump_begin (int phase, int *flag_ptr);
+ dump_begin (int phase, dump_flags_t *flag_ptr);
/* Returns nonzero if tree dump PHASE has been initialized. */
int
@@ -246,10 +255,11 @@ private:
dump_switch_p_1 (const char *arg, struct dump_file_info *dfi, bool doglob);
int
- dump_enable_all (int flags, const char *filename);
+ dump_enable_all (dump_flags_t flags, const char *filename);
int
- opt_info_enable_passes (int optgroup_flags, int flags, const char *filename);
+ opt_info_enable_passes (int optgroup_flags, dump_flags_t flags,
+ const char *filename);
private: