aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/runtime/mkpreempt.go2
-rw-r--r--src/runtime/preempt_arm64.s2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/mkpreempt.go b/src/runtime/mkpreempt.go
index 08500a90d5..6a9cf77a43 100644
--- a/src/runtime/mkpreempt.go
+++ b/src/runtime/mkpreempt.go
@@ -370,7 +370,7 @@ func genARM64() {
p("MOVD -8(RSP), R29") // restore frame pointer
p("MOVD (RSP), R27") // load PC to REGTMP
p("ADD $%d, RSP", l.stack+16) // pop frame (including the space pushed by sigctxt.pushCall)
- p("JMP (R27)")
+ p("RET (R27)")
}
func genMIPS(_64bit bool) {
diff --git a/src/runtime/preempt_arm64.s b/src/runtime/preempt_arm64.s
index c27d475dee..31ec9d940f 100644
--- a/src/runtime/preempt_arm64.s
+++ b/src/runtime/preempt_arm64.s
@@ -82,4 +82,4 @@ TEXT ·asyncPreempt(SB),NOSPLIT|NOFRAME,$0-0
MOVD -8(RSP), R29
MOVD (RSP), R27
ADD $512, RSP
- JMP (R27)
+ RET (R27)