]> Cypherpunks.ru repositories - gostls13.git/commit
cmd/internal/obj/ppc64: generate small, shifted constants in register
authorPaul E. Murphy <murp@ibm.com>
Mon, 18 Sep 2023 22:14:03 +0000 (17:14 -0500)
committerPaul Murphy <murp@ibm.com>
Wed, 4 Oct 2023 19:10:19 +0000 (19:10 +0000)
commit36ecff0893e8f30c2ff659acf8c62401f4dcebf7
tree0f50e6029ea9e5b7dc136f2af0030cb43db645c9
parente47cab13a5acfb99ed6e62eeb51772af94c5f526
cmd/internal/obj/ppc64: generate small, shifted constants in register

Check for shifted 16b constants, and transform them to avoid the load
penalty. This should be much faster than loading, and reduce binary
size by reducing the constant pool size.

Change-Id: I6834e08be7ca88e3b77449d226d08d199db84299
Reviewed-on: https://go-review.googlesource.com/c/go/+/531119
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Lynn Boger <laboger@linux.vnet.ibm.com>
Reviewed-by: Michael Pratt <mpratt@google.com>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Run-TryBot: Paul Murphy <murp@ibm.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/cmd/asm/internal/asm/testdata/ppc64.s
src/cmd/internal/obj/ppc64/obj9.go
test/codegen/constants.go [new file with mode: 0644]