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
cmd/compile: remove GOEXPERIMENT=nounified #57410
Comments
Change https://go.dev/cl/458624 mentions this issue: |
Change https://go.dev/cl/458623 mentions this issue: |
Change https://go.dev/cl/458617 mentions this issue: |
Change https://go.dev/cl/458622 mentions this issue: |
Change https://go.dev/cl/458619 mentions this issue: |
Change https://go.dev/cl/458618 mentions this issue: |
Change https://go.dev/cl/458575 mentions this issue: |
Change https://go.dev/cl/458620 mentions this issue: |
Change https://go.dev/cl/458616 mentions this issue: |
Change https://go.dev/cl/458621 mentions this issue: |
Change https://go.dev/cl/458615 mentions this issue: |
This code path is unreachable anyway, and it adds new uses of Type.Pkg, which shouldn't be used anymore. Mark Type.Pkg as deprecated while here. Updates #57410. Change-Id: I1eec1c8ed99207d58d0ba0c44822bbad29dc64f3 Reviewed-on: https://go-review.googlesource.com/c/go/+/458575 Reviewed-by: David Chase <drchase@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Cherry Mui <cherryyz@google.com>
This CL removes the GOEXPERIMENT=nounified knob, and any conditional statements that depend on that knob. Further CLs to remove unreachable code follow this one. Updates #57410. Change-Id: I39c147e1a83601c73f8316a001705778fee64a91 Reviewed-on: https://go-review.googlesource.com/c/go/+/458615 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Cherry Mui <cherryyz@google.com>
The use of typecheck.Resolve was previously necessary to interoperate with the non-unified frontend, because it hooked into iimport. It's no longer necessary with unified IR, where we can just lookup the ".inittask" symbol and access Def directly. Updates #57410. Change-Id: I73bdfd53f65988ececd2b777743cd8b591a6db48 Reviewed-on: https://go-review.googlesource.com/c/go/+/458616 Auto-Submit: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Keith Randall <khr@google.com> Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@golang.org>
This flag forced the compiler to eagerly type check all available inline function bodies, which presumably was useful in the early days of implementing inlining support. However, it shouldn't have any significance with the unified frontend, since the same code paths are used for constructing normal function bodies as for inlining. Updates #57410. Change-Id: I6842cf86bcd0fbf22ac336f2fc0b7b8fe14bccca Reviewed-on: https://go-review.googlesource.com/c/go/+/458617 Reviewed-by: Keith Randall <khr@golang.org> Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@google.com> Auto-Submit: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gopher Robot <gobot@golang.org>
Now that GOEXPERIMENT=nounified is removed, we can assume InlineCall and HaveInlineBody will always be overridden with the unified frontend's implementations. Similarly, we can assume expandDecl will never be called. This CL changes the code paths into Fatalfs, so subsequent CLs can remove all the unreachable code. Updates #57410. Change-Id: I2a0c3edb32916c30dd63c4dce4f1bd6f18e07468 Reviewed-on: https://go-review.googlesource.com/c/go/+/458618 Auto-Submit: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Keith Randall <khr@google.com> Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@golang.org>
In the types1 universe under the unified frontend, we never need to worry about type parameter constraints, so we only see pure interfaces. However, we might still see interfaces that contain union types, because of interfaces like "interface{ any | int }" (equivalent to just "any"). We can handle these without needing to actually represent type unions within types1 by simply mapping any union to "any". Updates #57410. Change-Id: I5e4efcf0339edbb01f4035c54fb6fb1f9ddc0c65 Reviewed-on: https://go-review.googlesource.com/c/go/+/458619 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Keith Randall <khr@golang.org>
This CL removes most of the code specific to the nounified frontend. To simplify review, it's a strict remove-only CL. Updates #57410. Change-Id: Ic3196570aa4286618c1d5e7fd0d0e6601a18195b Reviewed-on: https://go-review.googlesource.com/c/go/+/458620 Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Auto-Submit: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@google.com> Reviewed-by: Keith Randall <khr@golang.org>
These were used by the nounified frontend for representing uninstantiated generic types; however, the unified frontend only needs types1 to represent instantiated types. Updates #57410. Change-Id: Iac417fbf2b86f4e08bd7fdd26ae8ed17395ce833 Reviewed-on: https://go-review.googlesource.com/c/go/+/458621 Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@golang.org> Reviewed-by: Keith Randall <khr@google.com> TryBot-Result: Gopher Robot <gobot@golang.org>
This CL removes a handful of features that were only needed for the pre-unified frontends. In particular, Type.Pkg was a hack for iexport so that go/types.Var.Pkg could be precisely populated for struct fields and signature parameters by gcimporter, but it's no longer necessary with the unified export data format because we now write export data directly from types2-supplied type descriptors. Several other features (e.g., OrigType, implicit interfaces, type parameters on signatures) are no longer relevant to the unified frontend, because it only uses types1 to represent instantiated generic types. Updates #57410. Change-Id: I84fd1da5e0b65d2ab91d244a7bb593821ee916e7 Reviewed-on: https://go-review.googlesource.com/c/go/+/458622 Reviewed-by: Keith Randall <khr@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Matthew Dempsky <mdempsky@google.com> Reviewed-by: Keith Randall <khr@golang.org>
Tracking issue for removing GOEXPERIMENT=nounified for Go 1.21.
The text was updated successfully, but these errors were encountered: