From: Martin Liska Date: Wed, 7 Mar 2018 09:46:50 +0000 (+0100) Subject: Fix IPA profile merging, fixed in trunk with r253910. X-Git-Tag: releases/gcc-6.5.0~471 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d44d45d7b3ecee2fbec1a0e64ea71fcaa7466e45;p=thirdparty%2Fgcc.git Fix IPA profile merging, fixed in trunk with r253910. 2018-03-07 Martin Liska Backport from mainline 2018-03-05 Martin Liska * ipa-utils.c (ipa_merge_profiles): Do not merge alias or a function without profile. From-SVN: r258326 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 1b451894b3f5..ea0a7dcd912e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,11 @@ +2018-03-07 Martin Liska + + Backport from mainline + 2018-03-05 Martin Liska + + * ipa-utils.c (ipa_merge_profiles): Do not merge alias or + a function without profile. + 2018-03-07 Martin Liska Backport from mainline diff --git a/gcc/ipa-utils.c b/gcc/ipa-utils.c index 5eb7d5f31aad..cee0c6c95d0e 100644 --- a/gcc/ipa-utils.c +++ b/gcc/ipa-utils.c @@ -403,6 +403,8 @@ ipa_merge_profiles (struct cgraph_node *dst, if (!dst->count) return; + if (!src->count || src->alias) + return; if (symtab->dump_file) { fprintf (symtab->dump_file, "Merging profiles of %s/%i to %s/%i\n",