Closed
Description
Go version
go version go1.22.3 linux/arm64
Output of go env
in your module/workspace:
GOARCH='arm64'
What did you do?
Currently, x/benchmarks/sweet
fails to run gvisor
(which is enabled by default) on linux/arm64: ./sweet run ...
What did you see happen?
gvisor
only runs on linux/amd64. (see more: golang/benchmarks@34853f5).
What did you expect to see?
I think it's reasonable to only enable gvisor
for amd64
. E.g., a simple patch would be:
sweet/cmd/sweet/benchmark.go | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/sweet/cmd/sweet/benchmark.go b/sweet/cmd/sweet/benchmark.go
index 482d6a7..aaa3457 100644
--- a/sweet/cmd/sweet/benchmark.go
+++ b/sweet/cmd/sweet/benchmark.go
@@ -95,10 +95,13 @@ var benchmarkGroups = func() map[string][]*benchmark {
allBenchmarksMap["etcd"],
allBenchmarksMap["go-build"],
allBenchmarksMap["gopher-lua"],
- allBenchmarksMap["gvisor"],
allBenchmarksMap["markdown"],
allBenchmarksMap["tile38"],
}
+ if runtime.GOARCH == "amd64" {
+ m["default"] = append(m["default"][:7], m["default"][6:]...)
+ m["default"][6] = allBenchmarksMap["gvisor"]
+ }
for i := range allBenchmarks {
m["all"] = append(m["all"], &allBenchmarks[i])
cc @mknyszek