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: slow bitmap generation for large array of zero-size elements #20739

Closed
mdempsky opened this issue Jun 20, 2017 · 3 comments
Closed
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@mdempsky
Copy link
Member

This (nonsense, but valid) program takes a very long time to compile because of stack bitmap generation:

package f

func F() {
    var x struct {
            x *int
            w [1e10][1e10][1e10][0]*int
            y *int
    }
    println(&x)
}

The easy fix is to short-circuit generating stack bitmaps for zero-size types.

@mdempsky mdempsky added this to the Go1.10 milestone Jun 20, 2017
@bradfitz bradfitz added the NeedsFix The path to resolution is known, but the work has not been done. label Jun 20, 2017
@meggamind
Copy link

Can I pick this issue ?

@mdempsky mdempsky self-assigned this Jun 22, 2017
@mdempsky
Copy link
Member Author

@meggamind Thanks, but I already have a fix + general cleanup for the issue. I would suggest another issue.

You're of course welcome to still look into it if you're just looking for practice working on the compiler.

@gopherbot
Copy link

Change https://golang.org/cl/64471 mentions this issue: cmd/compile: refactor onebitwalktype1

@golang golang locked and limited conversation to collaborators Sep 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

4 participants