This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [GOOGLE] Sets cgraph_node count during annotation


Looks good.

David

On Thu, Sep 19, 2013 at 1:15 PM, Dehao Chen <dehao@google.com> wrote:
> This patch sets cgraph_node count during AutoFDO annotation, otherwise
> execute_fixup_cfg will clear all the BB counts.
>
> bootstrapped and passed regression test.
>
> OK for google-4_8 branch?
>
> Thanks,
> Dehao
>
> Index: gcc/auto-profile.c
> ===================================================================
> --- gcc/auto-profile.c (revision 202753)
> +++ gcc/auto-profile.c (working copy)
> @@ -1234,6 +1234,7 @@ afdo_annotate_cfg (void)
>
>    if (s == NULL)
>      return;
> +  cgraph_get_node (current_function_decl)->count = s->head_count ();
>    ENTRY_BLOCK_PTR->count = s->head_count ();
>    gcov_type max_count = ENTRY_BLOCK_PTR->count;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]