]> Cypherpunks repositories - gostls13.git/commit
cmd/dist, internal/abi: support bootstrapping with gccgo
authorIan Lance Taylor <iant@golang.org>
Wed, 21 Jun 2023 22:27:20 +0000 (15:27 -0700)
committerGopher Robot <gobot@golang.org>
Tue, 27 Jun 2023 21:15:37 +0000 (21:15 +0000)
commit6691f438c38d103e9399cd203286642b68257230
treedbaa088831509ca28f4020bcf8909b3b80071e18
parent942c1c12d89a53071ccd883e16d84af2001f2557
cmd/dist, internal/abi: support bootstrapping with gccgo

The required gc bootstrap compiler, 1.17, has an internal/lazyregexp
package. It permits that package to be imported by internal/profile
while bootstrapping. The gccgo compiler also has an internal/lazyregexp
package, but it does not permit the gc compiler to import it.

Permit bootstrapping with gccgo by adding internal/lazyregexp to the
list of bootstrap directories.

The gccgo compiler recognizes the magic functions internal/abi.FuncPCABI0
and FuncPCABIInternal, but only in the internal/abi package, not
in the bootstrapping internal/abi package.

Permit bootstrapping with gccgo by adding definitions of those functions
with build tags so that they are only used by gccgo.

Fixes #60913

Change-Id: I3a78848d545db13314409d170d63f4cc737ca12e
Reviewed-on: https://go-review.googlesource.com/c/go/+/505036
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Austin Clements <austin@google.com>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
src/cmd/dist/buildtool.go
src/internal/abi/funcpc.go
src/internal/abi/funcpc_gccgo.go [new file with mode: 0644]