* tree-inline.h (count_insns_seq): Delete prototype.
(estimate_num_insns_seq): Define prototype.
* tree-inline.c (count_insns_seq): Delete.
(estimate_num_insns_seq): Remove static qualifier.
* tree-eh.c (decide_copy_try_finally): Replace use of count_insns_seq
with estimate_num_insns_seq.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@228075
138bc75d-0d04-0410-961f-
82ee72b054a4
+2015-09-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
+
+ * tree-inline.h (count_insns_seq): Delete prototype.
+ (estimate_num_insns_seq): Define prototype.
+ * tree-inline.c (count_insns_seq): Delete.
+ (estimate_num_insns_seq): Remove static qualifier.
+ * tree-eh.c (decide_copy_try_finally): Replace use of count_insns_seq
+ with estimate_num_insns_seq.
+
2015-09-24 Richard Biener <rguenther@suse.de>
* tree-ssa-sccvn.h (vn_reference_op_struct): Add clique and base
2015-09-24 Richard Biener <rguenther@suse.de>
* tree-ssa-sccvn.h (vn_reference_op_struct): Add clique and base
}
/* Finally estimate N times, plus N gotos. */
}
/* Finally estimate N times, plus N gotos. */
- f_estimate = count_insns_seq (finally, &eni_size_weights);
+ f_estimate = estimate_num_insns_seq (finally, &eni_size_weights);
f_estimate = (f_estimate + 1) * ndests;
/* Switch statement (cost 10), N variable assignments, N gotos. */
f_estimate = (f_estimate + 1) * ndests;
/* Switch statement (cost 10), N variable assignments, N gotos. */
the statements in the statement sequence STMTS.
WEIGHTS contains weights attributed to various constructs. */
the statements in the statement sequence STMTS.
WEIGHTS contains weights attributed to various constructs. */
-static
-int estimate_num_insns_seq (gimple_seq stmts, eni_weights *weights)
+int
+estimate_num_insns_seq (gimple_seq stmts, eni_weights *weights)
{
int cost;
gimple_stmt_iterator gsi;
{
int cost;
gimple_stmt_iterator gsi;
eni_time_weights.return_cost = 2;
}
eni_time_weights.return_cost = 2;
}
-/* Estimate the number of instructions in a gimple_seq. */
-
-int
-count_insns_seq (gimple_seq seq, eni_weights *weights)
-{
- gimple_stmt_iterator gsi;
- int n = 0;
- for (gsi = gsi_start (seq); !gsi_end_p (gsi); gsi_next (&gsi))
- n += estimate_num_insns (gsi_stmt (gsi), weights);
-
- return n;
-}
-
/* Install new lexical TREE_BLOCK underneath 'current_block'. */
/* Install new lexical TREE_BLOCK underneath 'current_block'. */
int estimate_move_cost (tree type, bool);
int estimate_num_insns (gimple *, eni_weights *);
int estimate_num_insns_fn (tree, eni_weights *);
int estimate_move_cost (tree type, bool);
int estimate_num_insns (gimple *, eni_weights *);
int estimate_num_insns_fn (tree, eni_weights *);
-int count_insns_seq (gimple_seq, eni_weights *);
+int estimate_num_insns_seq (gimple_seq, eni_weights *);
bool tree_versionable_function_p (tree);
extern tree remap_decl (tree decl, copy_body_data *id);
extern tree remap_type (tree type, copy_body_data *id);
bool tree_versionable_function_p (tree);
extern tree remap_decl (tree decl, copy_body_data *id);
extern tree remap_type (tree type, copy_body_data *id);