-
Notifications
You must be signed in to change notification settings - Fork 18k
cmd/compile: strange use of GOEXPERIMENT #22223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
It looks like there's a similar check in cmd/go/internal/work/build.go too. I think the intent was that @josharian wasn't confident the non-standard code paths enabled by experiments were safe for concurrency. Agreed the checks do not function as intended. |
If trivial, do for 1.10. Otherwise move to 1.11. |
Change https://golang.org/cl/80760 mentions this issue: |
Reopening this, because GOEXPERIMENT is now broken since that CL. I left comments on https://go-review.googlesource.com/c/go/+/80760 with details. /cc @rsc |
Change https://golang.org/cl/81776 mentions this issue: |
Duplicate cmd/compile check into cmd/go. Manually tested that "GOEXPERIMENT=fieldtrack make.bash" passes now. Updates #22223. Change-Id: I441970a8a5ad4aadf5bd4fbd4d6cc71847b43308 Reviewed-on: https://go-review.googlesource.com/81776 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
As far as I can tell this is a valid issue, but there is no trivial fix, and things are working today, so rolling this forward to 1.11. |
The original issue (that cmd/compile was erroneously checking the GOEXPERIMENT environment variable) is fixed, so I think this can be closed again. (I saw @bradfitz's comment on the CL, but didn't notice he reopened this issue.) |
cmd/compile/internal/gc/main.go looks at $GOEXPERIMENT and if it's non-empty disables concurrent compilation.
I can't tell why. GOEXPERIMENT is only meaningful during make.bash; after that the experiment set is baked into the toolchain and not reloaded from the environment.
I suspect this use of $GOEXPERIMENT should just be removed.
/cc @josharian @mdempsky
The text was updated successfully, but these errors were encountered: