]> Cypherpunks repositories - gostls13.git/commit
runtime: teach peephole optimizer that duffcopy clobbers X0
authorKeith Randall <khr@golang.org>
Fri, 6 Nov 2015 08:06:52 +0000 (00:06 -0800)
committerKeith Randall <khr@golang.org>
Fri, 6 Nov 2015 15:11:42 +0000 (15:11 +0000)
commitffb20631fc4d78ce3a4e84044ada7f8e55544996
tree3c0726647398a92069c7fb9c819e960449ca71af
parent59bac0be9050fbbb05c4d8876ab8ea546819a33c
runtime: teach peephole optimizer that duffcopy clobbers X0

Duffcopy now uses X0, as of 5cf281a.  Teach the peephole
optimizer that duffcopy clobbers X0 so that it does not
rename registers use X0 across the duffcopy instruction.

Fixes #13171

Change-Id: I389cbf1982cb6eb2f51e6152ac96736a8589f085
Reviewed-on: https://go-review.googlesource.com/16715
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Minux Ma <minux@golang.org>
Reviewed-by: Ilya Tocar <ilya.tocar@intel.com>
src/cmd/compile/internal/amd64/peep.go
src/cmd/compile/internal/amd64/prog.go
src/cmd/compile/internal/amd64/reg.go
test/fixedbugs/issue13171.go [new file with mode: 0644]