From e237976802f31e13e98cbde121fa0348f77d8df4 Mon Sep 17 00:00:00 2001 From: Roland Shoemaker Date: Tue, 24 Feb 2026 12:47:42 -0800 Subject: [PATCH] cmd/asm/internal/asm/testdata: add SB tests Add tests for the SB instruction which were omitted in CL 729501. Change-Id: Ia71940b813563a418011914660ee0f1aeaa78444 Reviewed-on: https://go-review.googlesource.com/c/go/+/748580 LUCI-TryBot-Result: Go LUCI Reviewed-by: Cherry Mui Auto-Submit: Roland Shoemaker --- src/cmd/asm/internal/asm/testdata/arm64.s | 1 + src/cmd/asm/internal/asm/testdata/arm64enc.s | 1 + src/cmd/asm/internal/asm/testdata/arm64error.s | 1 + 3 files changed, 3 insertions(+) diff --git a/src/cmd/asm/internal/asm/testdata/arm64.s b/src/cmd/asm/internal/asm/testdata/arm64.s index c7564726e6..6a44f0f5b0 100644 --- a/src/cmd/asm/internal/asm/testdata/arm64.s +++ b/src/cmd/asm/internal/asm/testdata/arm64.s @@ -287,6 +287,7 @@ TEXT foo(SB), DUPOK|NOSPLIT, $-8 HINT $0 // 1f2003d5 DMB $1 SVC + SB // ff3003d5 // encryption SHA256H V9.S4, V3, V2 // 6240095e diff --git a/src/cmd/asm/internal/asm/testdata/arm64enc.s b/src/cmd/asm/internal/asm/testdata/arm64enc.s index cc002a1584..dca6c78de4 100644 --- a/src/cmd/asm/internal/asm/testdata/arm64enc.s +++ b/src/cmd/asm/internal/asm/testdata/arm64enc.s @@ -762,5 +762,6 @@ TEXT asmtest(SB),DUPOK|NOSPLIT,$-8 VMOV V0.B[1], R11 // 0b3c030e VMOV V1.H[3], R12 // 2c3c0e0e VUSHR $6, V22.H8, V23.H8 // d7061a6f + SB // ff3003d5 RET diff --git a/src/cmd/asm/internal/asm/testdata/arm64error.s b/src/cmd/asm/internal/asm/testdata/arm64error.s index ce88e3ca54..71c025ca55 100644 --- a/src/cmd/asm/internal/asm/testdata/arm64error.s +++ b/src/cmd/asm/internal/asm/testdata/arm64error.s @@ -428,4 +428,5 @@ TEXT errors(SB),$0 AUTIBSP C // ERROR "illegal combination" AUTIA1716 $45 // ERROR "illegal combination" AUTIB1716 R0 // ERROR "illegal combination" + SB $1 // ERROR "illegal combination" RET