Commit 9dc4346a by Jan Hubicka Committed by Jan Hubicka

ipa-inline-analysis.c (estimate_function_body_sizes, [...]): Cap time calculations.


	* ipa-inline-analysis.c (estimate_function_body_sizes,
	inline_update_overall_summary): Cap time calculations.

From-SVN: r193259
parent efa1fe23
2012-11-06 Jan Hubicka <jh@suse.cz>
* ipa-inline-analysis.c (estimate_function_body_sizes,
inline_update_overall_summary): Cap time calculations.
2012-11-06 Uros Bizjak <ubizjak@gmail.com> 2012-11-06 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_init_machine_status): Do not * config/i386/i386.c (ix86_init_machine_status): Do not
...@@ -2442,6 +2442,8 @@ estimate_function_body_sizes (struct cgraph_node *node, bool early) ...@@ -2442,6 +2442,8 @@ estimate_function_body_sizes (struct cgraph_node *node, bool early)
{ {
time += this_time; time += this_time;
size += this_size; size += this_size;
if (time > MAX_TIME * INLINE_TIME_SCALE)
time = MAX_TIME * INLINE_TIME_SCALE;
} }
/* We account everything but the calls. Calls have their own /* We account everything but the calls. Calls have their own
...@@ -3323,7 +3325,11 @@ inline_update_overall_summary (struct cgraph_node *node) ...@@ -3323,7 +3325,11 @@ inline_update_overall_summary (struct cgraph_node *node)
info->size = 0; info->size = 0;
info->time = 0; info->time = 0;
for (i = 0; VEC_iterate (size_time_entry, info->entry, i, e); i++) for (i = 0; VEC_iterate (size_time_entry, info->entry, i, e); i++)
info->size += e->size, info->time += e->time; {
info->size += e->size, info->time += e->time;
if (info->time > MAX_TIME * INLINE_TIME_SCALE)
info->time = MAX_TIME * INLINE_TIME_SCALE;
}
estimate_calls_size_and_time (node, &info->size, &info->time, NULL, estimate_calls_size_and_time (node, &info->size, &info->time, NULL,
~(clause_t)(1 << predicate_false_condition), ~(clause_t)(1 << predicate_false_condition),
NULL, NULL, NULL); NULL, NULL, NULL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment