]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: use NEG/NEGW pseudo-instructions on riscv64
authorJoel Sing <joel@sing.id.au>
Mon, 2 Mar 2020 16:45:22 +0000 (03:45 +1100)
committerJoel Sing <joel@sing.id.au>
Sun, 15 Mar 2020 08:19:07 +0000 (08:19 +0000)
commit26154f31ad6c801d8bad5ef58df1e9263c6beec7
treec9dd979940d6dcea886b70bdf41cbe17331c995b
parent7b2f0ba5b91b4b2b659fb46638ff56f51be9b2b5
cmd/compile: use NEG/NEGW pseudo-instructions on riscv64

Also rewrite subtraction of zero to NEG/NEGW.

Change-Id: I216e286d1860055f2a07fe2f772cd50f366ea097
Reviewed-on: https://go-review.googlesource.com/c/go/+/221691
Reviewed-by: Cherry Zhang <cherryyz@google.com>
src/cmd/compile/internal/riscv64/ssa.go
src/cmd/compile/internal/ssa/gen/RISCV64.rules
src/cmd/compile/internal/ssa/gen/RISCV64Ops.go
src/cmd/compile/internal/ssa/opGen.go
src/cmd/compile/internal/ssa/rewriteRISCV64.go