]> Cypherpunks repositories - gostls13.git/commit
runtime: preserve darwin/arm{,64} callee-save registers
authorElias Naur <elias.naur@gmail.com>
Sat, 12 Mar 2016 11:13:11 +0000 (12:13 +0100)
committerAndrew Gerrand <adg@golang.org>
Thu, 14 Apr 2016 05:24:45 +0000 (05:24 +0000)
commitbfe54b9b0ebfa96fd8eb6c35365050e1111ee7f3
tree63698f644db7644b0f1e8261771fa1eac716546b
parent4e3a486f033599080003823296a98879eb0049c7
runtime: preserve darwin/arm{,64} callee-save registers

CL 14603 attempted to preserve the callee-save registers for
the darwin/arm runtime initialization routine, but I believe it
wasn't sufficient and resulted in the crash reported in issue

Saving and restoring the registers on the stack the same way
linux/arm does seems more obvious and fixes #14778, so do that.

Even though #14778 is not reproducible on darwin/arm64, I applied
a similar change there, and to linux/arm64 which obeys the same
calling convention.

Finally, this CL is a candidate for a 1.6 minor release for the same
reason CL 14603 was in a 1.5 minor release (as CL 16968). It is
small and only touches the iOS platforms and gomobile on darwin/arm
is currently useless without it.

Fixes #14778
Fixes #12590 (again)

Change-Id: I7401daf0bbd7c579a7e84761384a7b763651752a
Reviewed-on: https://go-review.googlesource.com/20621
Reviewed-by: David Crawshaw <crawshaw@golang.org>
Run-TryBot: Elias Naur <elias.naur@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-on: https://go-review.googlesource.com/22049
src/runtime/rt0_darwin_arm.s
src/runtime/rt0_darwin_arm64.s
src/runtime/rt0_linux_arm64.s