From 92254d4463efb5c3a91ccd6d62abe3f7587a145a Mon Sep 17 00:00:00 2001 From: Dmitriy Vyukov Date: Mon, 12 Aug 2013 21:36:33 +0400 Subject: [PATCH] runtime: fix ARM assembly formatting R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/12702048 --- src/pkg/runtime/asm_arm.s | 24 ++++++++++++------------ src/pkg/runtime/sys_linux_arm.s | 6 +++--- src/pkg/sync/atomic/asm_linux_arm.s | 8 ++++---- 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/src/pkg/runtime/asm_arm.s b/src/pkg/runtime/asm_arm.s index bc23b454df..6978ae4426 100644 --- a/src/pkg/runtime/asm_arm.s +++ b/src/pkg/runtime/asm_arm.s @@ -81,19 +81,19 @@ GLOBL runtime·main·f(SB),RODATA,$4 TEXT runtime·breakpoint(SB),NOSPLIT,$0-0 // gdb won't skip this breakpoint instruction automatically, // so you must manually "set $pc+=4" to skip it and continue. - WORD $0xe1200071 // BKPT 0x0001 + WORD $0xe1200071 // BKPT 0x0001 RET GLOBL runtime·goarm(SB), $4 TEXT runtime·asminit(SB),NOSPLIT,$0-0 // disable runfast (flush-to-zero) mode of vfp if runtime.goarm > 5 - MOVW runtime·goarm(SB), R11 - CMP $5, R11 - BLE 4(PC) - WORD $0xeef1ba10 // vmrs r11, fpscr - BIC $(1<<24), R11 - WORD $0xeee1ba10 // vmsr fpscr, r11 + MOVW runtime·goarm(SB), R11 + CMP $5, R11 + BLE 4(PC) + WORD $0xeef1ba10 // vmrs r11, fpscr + BIC $(1<<24), R11 + WORD $0xeee1ba10 // vmsr fpscr, r11 RET /* @@ -448,7 +448,7 @@ TEXT runtime·cgocallback_gofunc(SB),NOSPLIT,$8-12 // the linker analysis by using an indirect call. MOVW m, savedm-4(SP) CMP $0, m - B.NE havem + B.NE havem MOVW $runtime·needm(SB), R0 BL (R0) @@ -566,11 +566,11 @@ TEXT runtime·armcas(SB),NOSPLIT,$0-12 MOVW new+8(FP), R3 casl: LDREX (R1), R0 - CMP R0, R2 - BNE casfail + CMP R0, R2 + BNE casfail STREX R3, (R1), R0 - CMP $0, R0 - BNE casl + CMP $0, R0 + BNE casl MOVW $1, R0 RET casfail: diff --git a/src/pkg/runtime/sys_linux_arm.s b/src/pkg/runtime/sys_linux_arm.s index 3e3709f92d..0e540f1c84 100644 --- a/src/pkg/runtime/sys_linux_arm.s +++ b/src/pkg/runtime/sys_linux_arm.s @@ -371,7 +371,7 @@ casagain: MOVW new+8(FP), R1 BL cas<>(SB) BCC cascheck - MOVW $1, R0 + MOVW $1, R0 RET cascheck: // Kernel lies; double-check. @@ -380,7 +380,7 @@ cascheck: MOVW 0(R2), R3 CMP R0, R3 BEQ casagain - MOVW $0, R0 + MOVW $0, R0 RET TEXT runtime·casp(SB),NOSPLIT,$0 @@ -439,5 +439,5 @@ TEXT runtime·closeonexec(SB),NOSPLIT,$0 MOVW $2, R1 // F_SETFD MOVW $1, R2 // FD_CLOEXEC MOVW $SYS_fcntl, R7 - SWI $0 + SWI $0 RET diff --git a/src/pkg/sync/atomic/asm_linux_arm.s b/src/pkg/sync/atomic/asm_linux_arm.s index 50d42ed91a..b78c7fa038 100644 --- a/src/pkg/sync/atomic/asm_linux_arm.s +++ b/src/pkg/sync/atomic/asm_linux_arm.s @@ -35,7 +35,7 @@ TEXT ·CompareAndSwapUint32(SB),NOSPLIT,$0 MOVW old+4(FP), R0 casagain: MOVW new+8(FP), R1 - BL cas<>(SB) + BL cas<>(SB) BCC cascheck MOVW $1, R0 casret: @@ -88,7 +88,7 @@ TEXT kernelCAS64<>(SB),NOSPLIT,$0 MOVW R1, (R1) MOVW $4(FP), R0 // oldval MOVW $12(FP), R1 // newval - BL cas64<>(SB) + BL cas64<>(SB) MOVW.CS $1, R0 // C is set if the kernel has changed *ptr MOVW.CC $0, R0 MOVW R0, 20(FP) @@ -124,7 +124,7 @@ TEXT setupAndCallCAS64<>(SB),NOSPLIT,$-4 MOVW.CS R1, PC MOVB runtime·armArch(SB), R0 // LDREXD, STREXD only present on ARMv6K or higher - CMP $6, R0 // TODO(minux): how to differentiate ARMv6 with ARMv6K? + CMP $6, R0 // TODO(minux): how to differentiate ARMv6 with ARMv6K? MOVW.CS $·armCompareAndSwapUint64(SB), R1 MOVW.CS R1, armCAS64(SB) MOVW.CS R1, PC @@ -140,7 +140,7 @@ TEXT ·CompareAndSwapUint64(SB),NOSPLIT,$-4 MOVW armCAS64(SB), R0 CMP $0, R0 MOVW.NE R0, PC - B setupAndCallCAS64<>(SB) + B setupAndCallCAS64<>(SB) TEXT ·AddInt64(SB),NOSPLIT,$0 B ·addUint64(SB) -- 2.48.1