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: stack overflow instead of initialization loop error #23093

Closed
griesemer opened this issue Dec 12, 2017 · 2 comments

Comments

Projects
None yet
3 participants
@griesemer
Copy link
Contributor

commented Dec 12, 2017

https://play.golang.org/p/7e5OO_qt0m correctly reports an initialization loop error. But cmd/compile (1.10 Beta) crashes with a stack overflow.

Superficially looks like a new error in the inlining code.

@griesemer griesemer added the NeedsFix label Dec 12, 2017

@griesemer griesemer added this to the Go1.10 milestone Dec 12, 2017

@mdempsky

This comment has been minimized.

Copy link
Member

commented Dec 12, 2017

The regression was introduced in c4b65fa.

I think the issue is the new code in hairyVisitor doesn't check if the named closure being called is a global or local variable. In inlnode, there's extra code in reassigned to make sure we don't try inlining a call to a global closure. That code was missed when the logic was copied into hairyVisitor.

@gopherbot

This comment has been minimized.

Copy link

commented Dec 12, 2017

Change https://golang.org/cl/83538 mentions this issue: cmd/compile: remove broken inlining accounting code

@gopherbot gopherbot closed this in 13bf4ad Dec 12, 2017

@golang golang locked and limited conversation to collaborators Dec 12, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.