]> Cypherpunks repositories - gostls13.git/commit
runtime, runtime/cgo: conform to PIC register use rules in ppc64 asm
authorMichael Hudson-Doyle <michael.hudson@canonical.com>
Thu, 8 Oct 2015 09:49:39 +0000 (22:49 +1300)
committerMichael Hudson-Doyle <michael.hudson@canonical.com>
Sun, 18 Oct 2015 23:36:39 +0000 (23:36 +0000)
commit6deb3c0619240c5b2f5d28e1f038eee6ac942318
treecb43064233cae8d33c16bb1ac18b7e277df2c2da
parentb8f8969fbd91e8c6a1a6e523be91a99f92d0f809
runtime, runtime/cgo: conform to PIC register use rules in ppc64 asm

PIC code on ppc64le uses R2 as a TOC pointer and when calling a function
through a function pointer must ensure the function pointer is in R12.  These
rules are easy enough to follow unconditionally in our assembly, so do that.

Change-Id: Icfc4e47ae5dfbe15f581cbdd785cdeed6e40bc32
Reviewed-on: https://go-review.googlesource.com/15526
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/runtime/asm_ppc64x.s
src/runtime/cgo/asm_ppc64x.s
src/runtime/cgo/gcc_ppc64x.S
src/runtime/rt0_linux_ppc64.s
src/runtime/rt0_linux_ppc64le.s
src/runtime/sys_linux_ppc64x.s