Skip to content
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

x/build/cmd/relui: go1.21.0.linux-armv6l built with GOARM=7 #62164

Closed
ksgriggs opened this issue Aug 20, 2023 · 3 comments
Closed

x/build/cmd/relui: go1.21.0.linux-armv6l built with GOARM=7 #62164

ksgriggs opened this issue Aug 20, 2023 · 3 comments
Labels
Builders x/build issues (builders, bots, dashboards) NeedsFix The path to resolution is known, but the work has not been done. Unfortunate
Milestone

Comments

@ksgriggs
Copy link

ksgriggs commented Aug 20, 2023

What version of Go are you using (go version)?

$ go version
1.21.0

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

Linux raspberrypi 6.1.21+ #1642 Mon Apr 3 17:19:14 BST 2023 armv6l GNU/Linux

Raspbian GNU/Linux 11 (bullseye)

go env Output
$ go env
Illegal instruction

What did you do?

Installed go 1.21.0 onto two different Raspberry Pi zero w and get the same illegal instruction output when running go.
I installed https://go.dev/dl/go1.21.0.linux-armv6l.tar.gz. Version 1.20.7 works.

  1. rm -rf /usr/local/go && tar -C /usr/local -xzf go1.21.0.linux-armv6l.tar.gz
  2. go version

What did you expect to see?

When running "go version" I expected to see the go version output and not "illegal instruction"

What did you see instead?

illegal instruction

@seankhliao seankhliao changed the title Go 1.21.0 illegal instruction on Raspberry Pi zero w. go1.21.0.linux-armv6l built with GOARM=7 Aug 20, 2023
@seankhliao
Copy link
Member

seems like it was built with GOARM=7 instead of 6

go: go1.21.0
	path	cmd/go
	build	-buildmode=exe
	build	-compiler=gc
	build	-gcflags=cmd/...=-dwarf=false
	build	-trimpath=true
	build	DefaultGODEBUG=panicnil=1
	build	CGO_ENABLED=0
	build	GOARCH=arm
	build	GOOS=linux
	build	GOARM=7

The arm64 artifact by contrast has no explicit GOARM set

go: go1.21.0
	path	cmd/go
	build	-buildmode=exe
	build	-compiler=gc
	build	-gcflags=cmd/...=-dwarf=false
	build	-trimpath=true
	build	DefaultGODEBUG=panicnil=1
	build	CGO_ENABLED=0
	build	GOARCH=arm64
	build	GOOS=linux

cc @golang/release

@dmitshur dmitshur added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Aug 20, 2023
@dmitshur dmitshur changed the title go1.21.0.linux-armv6l built with GOARM=7 x/build/cmd/relui: go1.21.0.linux-armv6l built with GOARM=7 Aug 20, 2023
@dmitshur dmitshur added this to the Unreleased milestone Aug 20, 2023
@gopherbot gopherbot added the Builders x/build issues (builders, bots, dashboards) label Aug 20, 2023
@dmitshur
Copy link
Contributor

dmitshur commented Aug 20, 2023

Indeed, thanks for reporting.

It was set to GOARM=6 in 1.20 and older because the release target used the linux-arm-aws builder, and that builder has GOARM=6 in its environment. For Go 1.21.0, it's built on a linux-amd64 builder via make.bash -distpack, and GOARM wasn't set in the release target's environment explicitly, so it ended up defaulting to 7 in make.bash.

$ go version -m ./go1.21.0/bin/go | tail -n 3
	build	GOARCH=arm
	build	GOOS=linux
	build	GOARM=7
$ go version -m ./go1.20.7/bin/go | tail -n 3
	build	GOARCH=arm
	build	GOOS=linux
	build	GOARM=6

The arm64 targets aren't affected because GOARM is for arm (32-bit) only and GOARM64 hasn't been added yet (see #60905 and #62129).

@dmitshur dmitshur added Unfortunate NeedsDecision Feedback is required from experts, contributors, and/or the community before a change can be made. and removed NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Aug 20, 2023
@dmitshur dmitshur modified the milestones: Unreleased, Go1.21.1 Aug 20, 2023
@gopherbot
Copy link

Change https://go.dev/cl/521555 mentions this issue: internal/releasetargets: set GOARM=6 for linux-armv6l

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Builders x/build issues (builders, bots, dashboards) NeedsFix The path to resolution is known, but the work has not been done. Unfortunate
Projects
Archived in project
Development

No branches or pull requests

4 participants