]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: implement some moves using non-overlapping reads&writes
authorKeith Randall <khr@google.com>
Tue, 30 Oct 2018 19:58:50 +0000 (12:58 -0700)
committerKeith Randall <khr@golang.org>
Tue, 30 Oct 2018 20:27:03 +0000 (20:27 +0000)
commit0ad332d80cf3e2bbeef5f1e5f5eb50272bbde92e
tree70a1799013122163e84bade9e89ffa85d911ee0a
parent56b7c61c5e88e684c1bdb3b9ae61dadbeda96fd0
cmd/compile: implement some moves using non-overlapping reads&writes

For moves >8,<16 bytes, do a move using non-overlapping loads/stores
if it would require no more instructions.

This helps a bit with the case when the move is from a static
constant, because then the code to materialize the value being moved
is smaller.

Change-Id: Ie47a5a7c654afeb4973142b0a9922faea13c9b54
Reviewed-on: https://go-review.googlesource.com/c/146019
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
src/cmd/compile/internal/ssa/gen/AMD64.rules
src/cmd/compile/internal/ssa/rewriteAMD64.go
test/codegen/strings.go