]> Cypherpunks repositories - gostls13.git/commit
cmd/7g: reserve registers R26 to R32
authorDavid Crawshaw <crawshaw@golang.org>
Fri, 3 Apr 2015 16:43:43 +0000 (12:43 -0400)
committerDavid Crawshaw <crawshaw@golang.org>
Fri, 3 Apr 2015 18:25:09 +0000 (18:25 +0000)
commitca0adeddd5515a02b76f30e5b72eb202c65f5f2f
tree7aa00a95806739d447857974271eaec83bc5d173
parenta51d5f27e8a6fd97b27fb864cd284589c850836e
cmd/7g: reserve registers R26 to R32

These registers are not available for programs to use. Prior to this
change, the compiler would crash attempting to use ZR as a general
purpose register. Other programs would compile but on execution would
overwrite the G register and cause havoc.

Fixes linux/arm64 build.
Fixes #10304
Fixes #10320

Change-Id: I5cf51d3b77cfe3db7dd6377324950cafb02f8d8b
Reviewed-on: https://go-review.googlesource.com/8456
Reviewed-by: Minux Ma <minux@golang.org>
src/cmd/7g/reg.go
test/fixedbugs/issue10320.go [new file with mode: 0644]