]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: ensure temp register mask isn't empty
authorKeith Randall <khr@golang.org>
Tue, 17 Jan 2023 17:35:21 +0000 (09:35 -0800)
committerKeith Randall <khr@google.com>
Tue, 17 Jan 2023 18:21:06 +0000 (18:21 +0000)
commit9088c691dac424540f562d6271c5ee479e9f9d80
tree7b8871ac3e83ddeb62be8a15db00fac4f260c6e6
parentc0799f7015e6cae37c21294bb94f56050fda5f4e
cmd/compile: ensure temp register mask isn't empty

We need to avoid nospill registers at this point in regalloc.
Make sure that we don't restrict our register set to avoid registers
desired by other instructions, if the resulting set includes only
nospill registers.

Fixes #57846

Change-Id: I05478e4513c484755dc2e8621d73dac868e45a27
Reviewed-on: https://go-review.googlesource.com/c/go/+/461685
Reviewed-by: Keith Randall <khr@google.com>
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Cherry Mui <cherryyz@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
src/cmd/compile/internal/ssa/regalloc.go
test/fixedbugs/issue57846.go [new file with mode: 0644]