]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: use CDF to determine PGO inline threshold
authorCherry Mui <cherryyz@google.com>
Tue, 1 Nov 2022 16:33:58 +0000 (12:33 -0400)
committerCherry Mui <cherryyz@google.com>
Thu, 3 Nov 2022 16:00:30 +0000 (16:00 +0000)
commitb07e845e764806fa888cb4e99c8ace4625f0472f
tree551c84bb280ba74ad025c8555a572b1576170f7e
parent932330fdbf669e28748227148f3f633620a5a300
cmd/compile: use CDF to determine PGO inline threshold

Currently in PGO we use a percentage threshold to determine if a
callsite is hot. This CL uses a different method -- treating the
hottest callsites that make up cumulatively top X% of total edge
weights as hot (X=95 for now). This default might work better for
a wider range of profiles. (The absolute threshold can still be
changed by a flag.)

For #55022.

Change-Id: I7e3b6f0c3cf23f9a89dd5994c10075b498bf14ee
Reviewed-on: https://go-review.googlesource.com/c/go/+/447016
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Cherry Mui <cherryyz@google.com>
Reviewed-by: Michael Pratt <mpratt@google.com>
src/cmd/compile/internal/base/debug.go
src/cmd/compile/internal/inline/inl.go