From fdfb3067a8a27a7491c3b0f6eddedbd467495329 Mon Sep 17 00:00:00 2001 From: Jayanth Krishnamurthy Date: Wed, 11 Sep 2024 09:44:16 -0500 Subject: cmd/internal/obj/ppc64: support for extended mnemonics of BC BGT, BLT, BLE, BGE, BNE, BVS, BVC, and BEQ support by assembler. This will simplify the usage of BC constructs like BC 12, 30, LR <=> BEQ CR7, LR BC 12, 2, LR <=> BEQ CR0, LR BC 12, 0, target <=> BLT CR0, target BC 12, 2, target <=> BEQ CR0, target BC 12, 5, target <=> BGT CR1, target BC 12, 30, target <=> BEQ CR7, target BC 4, 6, target <=> BNE CR1, target BC 4, 5, target <=> BLE CR1, target code cleanup based on the above additions. Change-Id: I02fdb212b6fe3f85ce447e05f4d42118c9ce63b5 Cq-Include-Trybots: luci.golang.try:gotip-linux-ppc64_power10,gotip-linux-ppc64_power8,gotip-linux-ppc64le_power8,gotip-linux-ppc64le_power9,gotip-linux-ppc64le_power10 Reviewed-on: https://go-review.googlesource.com/c/go/+/612395 LUCI-TryBot-Result: Go LUCI Reviewed-by: Paul Murphy Reviewed-by: Carlos Amedee Reviewed-by: Dmitri Shuralyov Reviewed-by: Michael Pratt --- src/cmd/asm/internal/asm/testdata/ppc64.s | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/cmd/asm') diff --git a/src/cmd/asm/internal/asm/testdata/ppc64.s b/src/cmd/asm/internal/asm/testdata/ppc64.s index e7ab944a1d..f25072a17e 100644 --- a/src/cmd/asm/internal/asm/testdata/ppc64.s +++ b/src/cmd/asm/internal/asm/testdata/ppc64.s @@ -508,17 +508,26 @@ TEXT asmtest(SB),DUPOK|NOSPLIT,$0 BEQ 0(PC) // 41820000 BEQ CR1,0(PC) // 41860000 + BEQ CR0, LR // 4d820020 + BEQ CR7, LR // 4d9e0020 BGE 0(PC) // 40800000 BGE CR2,0(PC) // 40880000 + BGE CR6,LR // 4c980020 BGT 4(PC) // 41810010 BGT CR3,4(PC) // 418d0010 + BGT CR6, LR // 4d990020 BLE 0(PC) // 40810000 BLE CR4,0(PC) // 40910000 + BLE CR6, LR // 4c990020 BLT 0(PC) // 41800000 BLT CR5,0(PC) // 41940000 BNE 0(PC) // 40820000 + BNE CR6, LR // 4c9a0020 BLT CR6,0(PC) // 41980000 + BLT CR6, LR // 4d980020 BVC 0(PC) // 40830000 + BVC CR6, LR // 4c9b0020 + BVS CR6, LR // 4d9b0020 BVS 0(PC) // 41830000 JMP 8(PC) // 48000010 -- cgit v1.3-5-g45d5