PATCH RFC: Don't print branches never executed in profile.c
Ian Lance Taylor
iant@google.com
Thu Jun 18 00:26:00 GMT 2009
Ian Lance Taylor <iant@google.com> writes:
> There is code in profile.c to print the number of branches which were
> never executed. However, it was broken by this patch:
>
> Wed Nov 21 12:38:37 CET 2001 Jan Hubicka
>
> * profile.c (compute_branch_probabilites): Compute probabilities
> for entry/exit edges; estimate probabilities for zero counts.
>
> which accidentally changed the critical line to
>
> num_branches++, num_never_executed;
>
> so that num_never_executed is always zero.
>
> Since nobody has noticed this brokenness for more than seven years, I
> think we should simply remove num_never_executed.
>
> Does anybody object to this patch?
>
> Ian
>
>
> 2009-06-16 Ian Lance Taylor <iant@google.com>
>
> * profile.c (total_num_never_executed): Don't define.
> (compute_branch_probabilities): Don't count or print
> num_never_executed.
> (init_branch_prob): Don't set total_num_never_executed.
> (end_branch_prob): Don't print total_num_never_executed.
I received no reply. I have committed this patch.
Ian
More information about the Gcc-patches
mailing list