[Bug ipa/83532] [8 Regression] ICE in apply_scale, at profile-count.h:955
marxin at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jan 10 12:07:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83532
--- Comment #2 from Martin Liška <marxin at gcc dot gnu.org> ---
(In reply to Jan Hubicka from comment #1)
> Does this help? Seems we omit adjustment when producing partial function
> clone.
>
> Index: tree-inline.c
> ===================================================================
> --- tree-inline.c (revision 256324)
> +++ tree-inline.c (working copy)
> @@ -2683,7 +2683,6 @@
> profile_count den = ENTRY_BLOCK_PTR_FOR_FN (src_cfun)->count;
> profile_count num = entry_block_map->count;
>
> - profile_count::adjust_for_ipa_scaling (&num, &den);
>
> cfun_to_copy = id->src_cfun = DECL_STRUCT_FUNCTION (callee_fndecl);
>
> @@ -2707,6 +2706,8 @@
> ENTRY_BLOCK_PTR_FOR_FN (cfun)->count = den;
> }
>
> + profile_count::adjust_for_ipa_scaling (&num, &den);
> +
> /* Must have a CFG here at this point. */
> gcc_assert (ENTRY_BLOCK_PTR_FOR_FN
> (DECL_STRUCT_FUNCTION (callee_fndecl)));
Let me test it.
More information about the Gcc-bugs
mailing list