1 /* Data and Control Flow Analysis for Trees.
2 Copyright (C) 2001-2014 Free Software Foundation, Inc.
3 Contributed by Diego Novillo <dnovillo@redhat.com>
5 This file is part of GCC.
7 GCC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3, or (at your option)
12 GCC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GCC; see the file COPYING3. If not see
19 <http://www.gnu.org/licenses/>. */
24 /* Location to track pending stmt for edge insertion. */
25 #define PENDING_STMT(e) ((e)->insns.g)
27 /* Garbage collection and PCH support for edge_def. */
28 extern void gt_ggc_mx (edge_def
*e
);
29 extern void gt_pch_nx (edge_def
*e
);
30 extern void gt_pch_nx (edge_def
*e
, gt_pointer_operator
, void *);
32 extern void init_empty_tree_cfg_for_function (struct function
*);
33 extern void init_empty_tree_cfg (void);
34 extern void fold_cond_expr_cond (void);
35 extern void start_recording_case_labels (void);
36 extern void end_recording_case_labels (void);
37 extern basic_block
label_to_block_fn (struct function
*, tree
);
38 #define label_to_block(t) (label_to_block_fn (cfun, t))
39 extern void cleanup_dead_labels (void);
40 extern void group_case_labels_stmt (gimple
);
41 extern void group_case_labels (void);
42 extern void replace_uses_by (tree
, tree
);
43 extern basic_block
single_noncomplex_succ (basic_block bb
);
44 extern void notice_special_calls (gimple
);
45 extern void clear_special_calls (void);
46 extern edge
find_taken_edge (basic_block
, tree
);
47 extern void gimple_debug_bb (basic_block
);
48 extern basic_block
gimple_debug_bb_n (int);
49 extern void gimple_debug_cfg (int);
50 extern void gimple_dump_cfg (FILE *, int);
51 extern void dump_cfg_stats (FILE *);
52 extern void debug_cfg_stats (void);
53 extern bool computed_goto_p (gimple
);
54 extern bool stmt_can_make_abnormal_goto (gimple
);
55 extern basic_block
get_abnormal_succ_dispatcher (basic_block
);
56 extern bool is_ctrl_stmt (gimple
);
57 extern bool is_ctrl_altering_stmt (gimple
);
58 extern bool simple_goto_p (gimple
);
59 extern bool stmt_ends_bb_p (gimple
);
60 extern bool assert_unreachable_fallthru_edge_p (edge
);
61 extern void delete_tree_cfg_annotations (void);
62 extern gimple
first_stmt (basic_block
);
63 extern gimple
last_stmt (basic_block
);
64 extern gimple
last_and_only_stmt (basic_block
);
65 extern void verify_gimple_in_seq (gimple_seq
);
66 extern void verify_gimple_in_cfg (struct function
*, bool);
67 extern tree
gimple_block_label (basic_block
);
68 extern void add_phi_args_after_copy_bb (basic_block
);
69 extern void add_phi_args_after_copy (basic_block
*, unsigned, edge
);
70 extern bool gimple_duplicate_sese_region (edge
, edge
, basic_block
*, unsigned,
72 extern bool gimple_duplicate_sese_tail (edge
, edge
, basic_block
*, unsigned,
74 extern void gather_blocks_in_sese_region (basic_block entry
, basic_block exit
,
75 vec
<basic_block
> *bbs_p
);
76 extern basic_block
move_sese_region_to_fn (struct function
*, basic_block
,
78 extern void dump_function_to_file (tree
, FILE *, int);
79 extern void debug_function (tree
, int) ;
80 extern void print_loops_bb (FILE *, basic_block
, int, int);
81 extern void print_loops (FILE *, int);
82 extern void debug (struct loop
&ref
);
83 extern void debug (struct loop
*ptr
);
84 extern void debug_verbose (struct loop
&ref
);
85 extern void debug_verbose (struct loop
*ptr
);
86 extern void debug_loops (int);
87 extern void debug_loop (struct loop
*, int);
88 extern void debug_loop_num (unsigned, int);
89 extern void remove_edge_and_dominated_blocks (edge
);
90 extern bool gimple_purge_dead_eh_edges (basic_block
);
91 extern bool gimple_purge_all_dead_eh_edges (const_bitmap
);
92 extern bool gimple_purge_dead_abnormal_call_edges (basic_block
);
93 extern bool gimple_purge_all_dead_abnormal_call_edges (const_bitmap
);
94 extern tree
gimplify_build3 (gimple_stmt_iterator
*, enum tree_code
,
95 tree
, tree
, tree
, tree
);
96 extern tree
gimplify_build2 (gimple_stmt_iterator
*, enum tree_code
,
98 extern tree
gimplify_build1 (gimple_stmt_iterator
*, enum tree_code
,
100 extern void extract_true_false_edges_from_block (basic_block
, edge
*, edge
*);
101 extern unsigned int execute_fixup_cfg (void);
102 extern unsigned int split_critical_edges (void);
104 #endif /* _TREE_CFG_H */