nebius/SWE-rebench-V2-PRs huggingface dataset:
Repository: appc/spec
Pull request #651 (2016-08-29 09:04:32)

schema: add s390x as a valid linux architecture
This adds a new `s390x` architecture label for linux.
It maps to IBM z/Architecture: https://en.wikipedia.org/wiki/Z/Architecture

`s390x` is a 64-bits, aligned access, big-endian architecture:
https://wiki.debian.org/ArchitectureSpecificsMemo

This new label corresponds to `uname -m` on Linux systems, to GOARCH and
to the usual distro naming.
The usual GNU triplet for this is `s390x-ibm-linux-gnu`.


Patch:
diff --git a/schema/types/labels.go b/schema/types/labels.go
index 167ce66..32d703c 100644
--- a/schema/types/labels.go
+++ b/schema/types/labels.go
@@ -21,7 +21,7 @@ import (
 )
 
 var ValidOSArch = map[string][]string{
-	"linux":   {"amd64", "i386", "aarch64", "aarch64_be", "armv6l", "armv7l", "armv7b", "ppc64", "ppc64le"},
+	"linux":   {"amd64", "i386", "aarch64", "aarch64_be", "armv6l", "armv7l", "armv7b", "ppc64", "ppc64le", "s390x"},
 	"freebsd": {"amd64", "i386", "arm"},
 	"darwin":  {"x86_64", "i386"},
 }


Test patch:
diff --git a/schema/types/labels_test.go b/schema/types/labels_test.go
index db40cba..4aaa037 100644
--- a/schema/types/labels_test.go
+++ b/schema/types/labels_test.go
@@ -81,6 +81,14 @@ func TestLabels(t *testing.T) {
 			`[{"name": "os", "value": "linux"}, {"name": "arch", "value": "ppc64be"}]`,
 			`bad arch "ppc64be" for linux`,
 		},
+		{
+			`[{"name": "os", "value": "linux"}, {"name": "arch", "value": "s390x"}]`,
+			``,
+		},
+		{
+			`[{"name": "os", "value": "linux"}, {"name": "arch", "value": "S390x"}]`,
+			`bad arch "S390x" for linux`,
+		},
 		{
 			`[{"name": "os", "value": "freebsd"}, {"name": "arch", "value": "amd64"}]`,
 			"",