]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: allow ops to specify clobbering input registers
authorkhr@golang.org <khr@golang.org>
Mon, 9 Jun 2025 23:44:46 +0000 (16:44 -0700)
committerGopher Robot <gobot@golang.org>
Wed, 30 Jul 2025 14:37:25 +0000 (07:37 -0700)
commit89a0af86b819ceb8095c686fc5109b40082bc8c5
treefe7f401df7145684715f57eab7c48f37d183079a
parent5e94d72158077411547287fc36f24b3121cca645
cmd/compile: allow ops to specify clobbering input registers

Same as clobbering fixed registers, but which register is clobbered
depends on which register was assigned to the input.

Add code similar to resultInArg0 processing that makes a register
copy before allowing the op to clobber the last available copy of a value.

(Will be used by subsequent CLs in this stack.)

Change-Id: I6bad88b2cb9ac3303d960ff0fb1611727292cfc4
Reviewed-on: https://go-review.googlesource.com/c/go/+/680335
Auto-Submit: Keith Randall <khr@golang.org>
Reviewed-by: Keith Randall <khr@google.com>
Reviewed-by: Jorropo <jorropo.pgm@gmail.com>
Reviewed-by: Mark Freeman <mark@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
src/cmd/compile/internal/ssa/_gen/main.go
src/cmd/compile/internal/ssa/op.go
src/cmd/compile/internal/ssa/regalloc.go