[go] cmd/compile: don't drop same register twice

0 views
Skip to first unread message

Keith Randall (Gerrit)

unread,
Feb 15, 2026, 10:19:05 AMFeb 15
to Keith Randall, goph...@pubsubhelper.golang.org, golang-...@googlegroups.com, Keith Randall, Dmitri Shuralyov, Dmitri Shuralyov, Jorropo, Go LUCI, golang-co...@googlegroups.com

Keith Randall submitted the change

Change information

Commit message:
cmd/compile: don't drop same register twice

For instructions that clobber both of their input registers, make
sure we don't clobber the same register twice when both input
registers are the same.

This is rare, but it can happen.

Fixes #77604
Change-Id: I794249cf43a8cc4ab3262055daef9193e2442f73
Reviewed-by: Keith Randall <k...@google.com>
Reviewed-by: Jorropo <jorro...@gmail.com>
Reviewed-by: Dmitri Shuralyov <dmit...@google.com>
Files:
  • M src/cmd/compile/internal/ssa/regalloc.go
  • A test/fixedbugs/issue77604.go
Change size: S
Delta: 2 files changed, 21 insertions(+), 1 deletion(-)
Branch: refs/heads/master
Submit Requirements:
  • requirement satisfiedCode-Review: +1 by Keith Randall, +2 by Jorropo, +1 by Dmitri Shuralyov
  • requirement satisfiedTryBots-Pass: LUCI-TryBot-Result+1 by Go LUCI
Open in Gerrit
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: merged
Gerrit-Project: go
Gerrit-Branch: master
Gerrit-Change-Id: I794249cf43a8cc4ab3262055daef9193e2442f73
Gerrit-Change-Number: 745621
Gerrit-PatchSet: 2
Gerrit-Owner: Keith Randall <k...@golang.org>
Gerrit-Reviewer: Dmitri Shuralyov <dmit...@google.com>
Gerrit-Reviewer: Jorropo <jorro...@gmail.com>
Gerrit-Reviewer: Keith Randall <k...@golang.org>
Gerrit-Reviewer: Keith Randall <k...@google.com>
Gerrit-CC: Dmitri Shuralyov <dmit...@golang.org>
open
diffy
satisfied_requirement
Reply all
Reply to author
Forward
0 new messages