]> Cypherpunks.ru repositories - gostls13.git/commit
cmd/asm: rename R18 to R18_PLATFORM on ARM64
authorCherry Zhang <cherryyz@google.com>
Fri, 2 Nov 2018 20:51:14 +0000 (16:51 -0400)
committerCherry Zhang <cherryyz@google.com>
Tue, 6 Nov 2018 20:10:12 +0000 (20:10 +0000)
commit35c05542938416cde6a366505c24568ea5ccd98e
tree0a67752f0e773fd8d612f95ab018ae90f2ae7d6c
parent95a4f793c077ab7b13fdb7505b65ff19a97a07f9
cmd/asm: rename R18 to R18_PLATFORM on ARM64

In ARM64 ABI, R18 is the "platform register", the use of which is
OS specific. The OS could choose to reserve this register. In
practice, it seems fine to use R18 on Linux but not on darwin (iOS).

Rename R18 to R18_PLATFORM to prevent accidental use. There is no
R18 usage within the standard library (besides tests, which are
updated).

Fixes #26110

Change-Id: Icef7b9549e2049db1df307a0180a3c90a12d7a84
Reviewed-on: https://go-review.googlesource.com/c/147218
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
doc/asm.html
src/cmd/asm/internal/arch/arch.go
src/cmd/asm/internal/asm/operand_test.go
src/cmd/asm/internal/asm/testdata/arm64.s
src/cmd/asm/internal/asm/testdata/arm64enc.s
src/cmd/internal/obj/arm64/doc.go