From: Amaan Qureshi Date: Fri, 20 Mar 2026 00:40:20 +0000 (-0400) Subject: s390x: set minimum architecture level to z10 X-Git-Tag: openssl-4.0.0~94 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=678a2c484a2f9940a3132fb5f584f6e1dc5a6aee;p=thirdparty%2Fopenssl.git s390x: set minimum architecture level to z10 The keccak1600 perlasm file (`keccak1600-s390x.pl`) emits `cijne`, a z10 compare-immediate-and-branch instruction, without declaring a minimum architecture level. GCC defaults to `-march=z900` on s390x, causing assembler errors when building with the default toolchain flags: keccak1600-s390x.S:399: Error: Unrecognized opcode: `cijne' z900 has been out of service since 2014, the Linux kernel requires z196 minimum, and clang already defaults to z10 on s390x. A `.machine "z10"` GAS directive in the generated assembly resolves the error by declaring the architecture level the file already requires. Ref: #27323 Reviewed-by: Eugene Syromiatnikov Reviewed-by: Nikola Pajkovsky Reviewed-by: Paul Dale Reviewed-by: Tomas Mraz MergeDate: Fri Mar 27 16:32:22 2026 (Merged from https://github.com/openssl/openssl/pull/30507) (cherry picked from commit 189cf6f0b873e21902e1b1fc6f85fd89d003b847) --- diff --git a/crypto/sha/asm/keccak1600-s390x.pl b/crypto/sha/asm/keccak1600-s390x.pl index 5bd5f04cdaf..696dcbb8638 100755 --- a/crypto/sha/asm/keccak1600-s390x.pl +++ b/crypto/sha/asm/keccak1600-s390x.pl @@ -67,6 +67,7 @@ my @rhotates = ([ 0, 1, 62, 28, 27 ], $code.=<<___; .text +.machine "z10" .type __KeccakF1600,\@function .align 32