Repository navigation
Run on arm64 Linux and on the BSDs, rather than only building for them - #111
Merged
Merged
Conversation
Two gaps, both of the same shape as the one the arch lanes exist to close. **arm64 was only ever exercised on Darwin.** macOS gave us the instruction set; it did not give us the kernel, the scheduler or the libc story that most of the world running this will have -- a server, a Raspberry Pi, a CI runner. `ubuntu-24.04-arm` is a NATIVE arm64 Linux runner, not emulation, so the os-matrix now covers it. **The BSDs were not built for at all, let alone run on.** Measured here first: freebsd/amd64, freebsd/arm64, openbsd/amd64, openbsd/arm64, netbsd/amd64, dragonfly/amd64, illumos/amd64 and solaris/amd64 all compile clean today. They are now in the cross-compile step, which is cheap and catches a build tag before somebody on one of those systems does. And three of them RUN the suite, in a virtual machine. The binary is built with the PINNED toolchain and then run inside the VM, rather than installing Go in the VM and building there. The Go a BSD packages is whatever that release froze, so building inside would silently test a different compiler from every other lane -- and this module's floor is 1.27.1, which the packaged one may not even satisfy. It works because this package is one package with no testdata: a single `go test -c` produces a binary that runs on its own. With `CGO_ENABLED=0` the operating system is reached only through the standard library, so the distance between Linux and FreeBSD here is much smaller than the distance between amd64 and s390x. Smaller is not none: file modes, path handling and what a syscall returns at the edges all differ, and a PDF reader opens files. This is a pilot, on one repository. If the lanes are green it belongs in the other nine.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two gaps, both the same shape as the one the arch lanes exist to close.
arm64 was only ever exercised on Darwin
macOS gave us the instruction set. It did not give us the kernel, the
scheduler, or the libc story that most of the world running this will have — a
server, a Raspberry Pi, a CI runner.
ubuntu-24.04-armis a native arm64Linux runner, not emulation, and the
os-matrixnow covers it.The BSDs were not built for at all, let alone run on
Measured here before writing a line of workflow — all clean today:
They are now in the cross-compile step, which is cheap and catches a build tag
before somebody on one of those systems does. And three of them run the
suite, in a virtual machine.
Why the test binary is cross-built on the host
It is built with the pinned toolchain and then run inside the VM, rather
than installing Go in the VM and building there. The Go a BSD packages is
whatever that release froze, so building inside would silently test a
different compiler from every other lane — and this module's floor is
1.27.1,which the packaged one may not even satisfy.
It works because this package is one package with no
testdata: a singlego test -cproduces a binary that runs on its own.What this claims, and what it does not
With
CGO_ENABLED=0the operating system is reached only through the standardlibrary, so the distance between Linux and FreeBSD here is much smaller than
the distance between amd64 and s390x. Smaller is not none: file modes, path
handling and what a syscall returns at the edges all differ, and a PDF reader
opens files.
This is a pilot, on one repository. If the lanes come back green it belongs
in the other nine; if one of them is red, that is the answer to a question
nobody here had asked yet.
🤖 Generated with Claude Code