]> Cypherpunks repositories - gostls13.git/commit
cmd/go: make PGO profile path per package
authorCherry Mui <cherryyz@google.com>
Mon, 27 Feb 2023 20:37:32 +0000 (15:37 -0500)
committerCherry Mui <cherryyz@google.com>
Mon, 6 Mar 2023 19:22:03 +0000 (19:22 +0000)
commit5987f3c2715d93cb52f05dcb1c29825507e1d625
tree248ac05e7316add5a50ed0a5510ca6ed02075acd
parent3eedba50b10ca9086646f12d7917912cff7d4d0a
cmd/go: make PGO profile path per package

Currently, the PGO profile path is global for a single go command
invocation, as it applies to all packages being built (or none).
With -pgo=auto mode with multiple main packages, packages from a
single go command invocation could have different profiles. So it
is necessary that the PGO profile path is per package, which is
this CL does.

For #58099.

Change-Id: I148a15970ec907272db85b4b27ad6b08c41d6c0c
Reviewed-on: https://go-review.googlesource.com/c/go/+/472357
Run-TryBot: Cherry Mui <cherryyz@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Michael Pratt <mpratt@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
src/cmd/go/internal/cfg/cfg.go
src/cmd/go/internal/load/pkg.go
src/cmd/go/internal/load/test.go
src/cmd/go/internal/work/exec.go
src/cmd/go/internal/work/gc.go