aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarlos Eduardo Seo <cseo@linux.vnet.ibm.com>2020-01-17 17:59:59 -0300
committerIan Lance Taylor <iant@golang.org>2020-04-03 22:09:47 +0000
commitb79c36dc9949177aa6e2e33fe5af61d4461676a4 (patch)
tree06698fe235a48c0852af0cd588930ee0d4840c76
parent9ed3fb84bc6148590757995c651bd4a6e85b4531 (diff)
downloadgo-b79c36dc9949177aa6e2e33fe5af61d4461676a4.tar.gz
go-b79c36dc9949177aa6e2e33fe5af61d4461676a4.zip
[release-branch.go1.13] runtime: fix wrong offset when calling ppc64x nanotime syscall
There is a wrong offset when getting the results of a clock_gettime syscall. Although the syscall will never be called in native ppc64x, QEMU doesn't implement VDSO, so it will return wrong values. For #36592 Fixes #38236 Change-Id: Icf838075228dcdd62cf2c1279aa983e5993d66ee Reviewed-on: https://go-review.googlesource.com/c/go/+/215397 Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com> (cherry picked from commit 71239b4f491698397149868c88d2c851de2cd49b) Reviewed-on: https://go-review.googlesource.com/c/go/+/227179 Reviewed-by: Carlos Eduardo Seo <cseo@linux.vnet.ibm.com> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
-rw-r--r--src/runtime/sys_linux_ppc64x.s2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/sys_linux_ppc64x.s b/src/runtime/sys_linux_ppc64x.s
index 13d23156bd..435cc2809a 100644
--- a/src/runtime/sys_linux_ppc64x.s
+++ b/src/runtime/sys_linux_ppc64x.s
@@ -251,7 +251,7 @@ fallback:
ADD $32, R1, R4
SYSCALL $SYS_clock_gettime
MOVD 32(R1), R3
- MOVD 48(R1), R5
+ MOVD 40(R1), R5
JMP finish
TEXT runtime·rtsigprocmask(SB),NOSPLIT|NOFRAME,$0-28