Skip to content

cmd/go: support multiple main packages with -pgo=auto #58099

Closed
@prattmic

Description

@prattmic

In Go 1.20, go build -pgo=auto can only be used with a single main package. Specifying multiple main packages (e.g., go build -pgo=auto cmd/compile cmd/link) is an error.

To support this, cmd/go needs to learn to build the transitive dependencies N times, once for each different profile used by each main package.

Follow up to #55022.

cc @cherrymui @aclements

Metadata

Metadata

Assignees

Labels

FrozenDueToAgeGoCommandcmd/goNeedsFixThe path to resolution is known, but the work has not been done.compiler/runtimeIssues related to the Go compiler and/or runtime.

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions