Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
runtime: large stack makes the program hang #26154
Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (
It looks like you're tripping across the boundary between stack-allocating and heap-allocating
I'm going to close as not-a-bug. Definitely odd, but I'd argue that with the heap-allocated
@aclements This is kind of a weird case, where the GC is collecting a single 11MB object each iteration. Probably a larger heap goal size would be useful in situations like these (although this particular situation is contrived enough to be irrelevant).
Perhaps the proper solution is to solve #23044 (comment). That would happen to space out these GCs, and would mean that when they did run, the cost of marking (0.72 ms in that example) would be amortized against the less frequent GC scheduling.