Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cmd/compile: internal compiler error: bad live variable at entry: [6]string value #45693

Closed
ALTree opened this issue Apr 22, 2021 · 3 comments
Closed

Comments

@ALTree
Copy link
Member

@ALTree ALTree commented Apr 22, 2021

$ gotip version
go version devel go1.17-14a18b7d25 Thu Apr 22 04:07:38 2021 +0000 windows/amd64
package p

func f() {
        var s string
        s = s + "" + s + "" + s + ""
        for true {
        }
}
$ gotip tool compile crash.go
crash.go:5:26: internal compiler error: bad live variable at entry of f: [6]string value

goroutine 20 [running]:
runtime/debug.Stack()
        D:/users/f65362c/alberto/other/gotip/src/runtime/debug/stack.go:24 +0x65
cmd/compile/internal/base.FatalfAt(0xc0000a4a00, 0x95d039, 0x1, 0xc0003d38d0, 0x0, 0xc0000a9354)
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/base/print.go:227 +0x157
cmd/compile/internal/liveness.(*liveness).epilogue(0xc0000f62c0)
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/liveness/plive.go:838 +0xc39
cmd/compile/internal/liveness.Compute(0xc0000f62c0, 0xc0003591e0, 0x972918, 0x1)
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/liveness/plive.go:1353 +0x8f
cmd/compile/internal/ssagen.genssa(0xc0000f62c0, 0xc0003c4f50)
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/ssagen/ssa.go:6564 +0x9e
cmd/compile/internal/ssagen.Compile(0xc0000f62c0, 0x0)
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/ssagen/pgen.go:175 +0x266
cmd/compile/internal/gc.compileFunctions.func2.1()
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/gc/compile.go:130 +0x65
created by cmd/compile/internal/gc.compileFunctions.func2
        D:/users/f65362c/alberto/other/gotip/src/cmd/compile/internal/gc/compile.go:128 +0xcf

Tentatively putting as relblocker in the 1.17 milestone since it's a tip regression, but feel free to re-label.

cc @randall77

@cuonglm
Copy link
Member

@cuonglm cuonglm commented Apr 22, 2021

Also cc @cherrymui @aclements @dr2chase, as this is on triggered with regabiargs enabled:

GOEXPERIMENT=regabiargs GOARCH=amd64 go tool compile issue45693.go

Compile succeed with:

GOEXPERIMENT=noregabiargs GOARCH=amd64 go tool compile issue45693.go

Loading

@cherrymui
Copy link
Contributor

@cherrymui cherrymui commented Apr 22, 2021

Thanks. I'll take a look.

Loading

@gopherbot
Copy link

@gopherbot gopherbot commented Apr 22, 2021

Change https://golang.org/cl/312670 mentions this issue: cmd/compile: keep call's args in elim dead auto pass

Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants