]> Cypherpunks repositories - gostls13.git/commit
cmd/compile/internal/devirtualize: sort equal weight CallStat.Hottest by name
authorMichael Pratt <mpratt@google.com>
Tue, 12 Sep 2023 18:23:15 +0000 (14:23 -0400)
committerGopher Robot <gobot@golang.org>
Tue, 12 Sep 2023 18:40:16 +0000 (18:40 +0000)
commit4b17b36b3f0ea85728d8690c93a6483764804441
tree59e628e11e3080a4f5a4ac294a7a030019159122
parente8ba0579e2913f96c65b96e0696d64ff5f1599c5
cmd/compile/internal/devirtualize: sort equal weight CallStat.Hottest by name

When two callees have equal weight, we need to sort by another criteria
to ensure that we get stable output.

Note that this is only for the CallStat debug JSON output. The actual
callee selection already does this secondary sort in
findHotConcreteCallee.

Change-Id: I0de105623c5ccc793ca6f5799ea25e57bc286722
Reviewed-on: https://go-review.googlesource.com/c/go/+/527796
Auto-Submit: Michael Pratt <mpratt@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/cmd/compile/internal/devirtualize/pgo.go