aboutsummaryrefslogtreecommitdiff
path: root/src/debug
diff options
context:
space:
mode:
authorCherry Mui <cherryyz@google.com>2023-02-28 18:43:14 -0500
committerCherry Mui <cherryyz@google.com>2023-03-06 19:22:18 +0000
commit74502e9bb4d732239fa684969ddb22e7b7345f3a (patch)
treeffe22011a8c9340cf35b446de5954219d3cd72c7 /src/debug
parent5987f3c2715d93cb52f05dcb1c29825507e1d625 (diff)
downloadgo-74502e9bb4d732239fa684969ddb22e7b7345f3a.tar.xz
cmd/go: support multiple main packages with -pgo=auto
In -pgo=auto mode, the go command finds a profile named default.pgo in the main package's directly, and if found, use it as the profile for the build. Currently we only support a single main package when -pgo=auto is used. When multiple main packages are included in a build, they may have different default profiles (or some have profiles whereas some don't), so a common dependent package would need to be built multiple times, with different profiles (or lack of). This CL handles this. To do so, we need to split (unshare) the dependency graph so they can attach different profiles. Fixes #58099. Change-Id: I1ad21361967aafbf5089d8d5e89229f95fe31276 Reviewed-on: https://go-review.googlesource.com/c/go/+/472358 Reviewed-by: Michael Pratt <mpratt@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Cherry Mui <cherryyz@google.com> Reviewed-by: Bryan Mills <bcmills@google.com>
Diffstat (limited to 'src/debug')
0 files changed, 0 insertions, 0 deletions