https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65076
--- Comment #53 from Jan Hubicka <hubicka at gcc dot gnu.org> --- This patch makes denominator to use resulting function size (not uninlined time like 4.9 did but getting the resulting fraction closer to 4.9 style): Index: ../../gcc/ipa-inline.c =================================================================== --- ../../gcc/ipa-inline.c (revision 221806) +++ ../../gcc/ipa-inline.c (working copy) @@ -1167,6 +1168,7 @@ edge_badness (struct cgraph_edge *edge, overall_growth += 256 * 256 - 256; denominator *= overall_growth; } + denominator *= inline_summaries->get (caller)->self_size + growth; badness = - numerator / denominator; Large function growht is now hit only 8 times and compile time seems down to: real 0m33.670s user 0m33.065s sys 0m0.522s code size seems 8% bigger than 4.9, runtime is good. The performance stays good with large-function-insns=10 and compile time further drops to: real 0m32.127s user 0m31.634s sys 0m0.520s I will run firefox benchmarks tonight.