diff --git a/src/arm.S b/src/arm.S index 281e69f724..dceb8d3b75 100644 --- a/src/arm.S +++ b/src/arm.S @@ -20,6 +20,7 @@ #endif .globl GLOBAL(vmNativeCall) +.align 2 GLOBAL(vmNativeCall): /* arguments: @@ -57,6 +58,7 @@ LOCAL(loop): ldmfd sp!, {r4-r6, pc} // restore non-volatile regs and return .globl GLOBAL(vmJump) +.align 2 GLOBAL(vmJump): mov lr, r0 ldr r0, [sp] @@ -69,6 +71,7 @@ GLOBAL(vmJump): #define CHECKPOINT_STACK 24 .globl GLOBAL(vmRun) +.align 2 GLOBAL(vmRun): // r0: function // r1: arguments @@ -85,6 +88,7 @@ GLOBAL(vmRun): blx r12 .globl GLOBAL(vmRun_returnAddress) +.align 2 GLOBAL(vmRun_returnAddress): add sp, sp, #12 ldmfd sp!, {r4-r11, lr} diff --git a/src/compile-arm.S b/src/compile-arm.S index a3f15f7c14..0f69903934 100644 --- a/src/compile-arm.S +++ b/src/compile-arm.S @@ -38,6 +38,7 @@ #define CONTINUATION_BODY 32 .globl GLOBAL(vmInvoke) +.align 2 GLOBAL(vmInvoke): /* arguments @@ -84,6 +85,7 @@ LOCAL(vmInvoke_argumentTest): blx r1 .globl GLOBAL(vmInvoke_returnAddress) +.align 2 GLOBAL(vmInvoke_returnAddress): // restore stack pointer ldr sp, [r8, #THREAD_SCRATCH] @@ -97,6 +99,7 @@ GLOBAL(vmInvoke_returnAddress): str r5, [r8, #THREAD_STACK] .globl GLOBAL(vmInvoke_safeStack) +.align 2 GLOBAL(vmInvoke_safeStack): #ifdef AVIAN_CONTINUATIONS @@ -174,6 +177,7 @@ LOCAL(vmInvoke_return): bx lr .globl GLOBAL(vmJumpAndInvoke) +.align 2 GLOBAL(vmJumpAndInvoke): #ifdef AVIAN_CONTINUATIONS // r0: thread