Skip to content

Commit 08b9640

Browse files
xen0ndr2chase
authored andcommitted
cmd/compile: teach regalloc to rightly do nothing on loong64 in case of dynlinking
This is needed before actual support for buildmode=plugin is added. Should not affect current behavior. Change-Id: I86371d7e373fd529cb8710850d7b0fbbf1eb52ca Reviewed-on: https://go-review.googlesource.com/c/go/+/480877 Reviewed-by: David Chase <[email protected]> Reviewed-by: Meidan Li <[email protected]> Reviewed-by: abner chenc <[email protected]> Reviewed-by: Cherry Mui <[email protected]> Run-TryBot: WANG Xuerui <[email protected]> TryBot-Result: Gopher Robot <[email protected]>
1 parent 346e06c commit 08b9640

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/cmd/compile/internal/ssa/regalloc.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -672,6 +672,8 @@ func (s *regAllocState) init(f *Func) {
672672
s.allocatable &^= 1 << 9 // R9
673673
case "arm64":
674674
// nothing to do
675+
case "loong64": // R2 (aka TP) already reserved.
676+
// nothing to do
675677
case "ppc64le": // R2 already reserved.
676678
// nothing to do
677679
case "riscv64": // X3 (aka GP) and X4 (aka TP) already reserved.

0 commit comments

Comments
 (0)