Closed
Description
$ go version
go version go1.15.5 linux/amd64
$ gotip version
go version devel +f423d616b1 Fri Nov 13 15:15:15 2020 +0000 linux/amd64
The following program:
package p
func f() {
var i, j int
_ = func() {
i = 32
j = j>>i | len([]int{})
}
}
Crashes the go1.15.5 and tip compilers when built for mips
:
$ GOARCH=mips go tool compile crash.go
00020 (crash.go:7) SRA $-1, R2, R2
00020 (crash.go:7) SRA $-1, R2, R2
00020 (crash.go:7) SRA $-1, R2, R2
00020 (crash.go:7) SRA $-1, R2, R2
crash.go:7:5: illegal combination SRA ADDCON REG REG
The go1.14.12 compiler compiles it with no issues.