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

in debug builds, detect stack overflow at runtime and output a partial stack trace #1616

Open
andrewrk opened this issue Oct 1, 2018 · 0 comments
Labels
enhancement Solving this issue will likely involve adding new logic or components to the codebase. standard library This issue involves writing Zig code for the standard library.
Milestone

Comments

@andrewrk
Copy link
Member

andrewrk commented Oct 1, 2018

I just debugged a stack overflow on windows that was solved by increasing the stack size for all executables. Once #157 is solved this can be replaced with a value based on call graph analysis.

But we still have chkstck calling @panic. When this happens we try to dump a stack trace, but this uses the stack, which just overflowed. So this can't work. This could potentially be a use case for @newStackCall.

@andrewrk andrewrk added this to the 0.5.0 milestone Oct 1, 2018
@andrewrk andrewrk added the standard library This issue involves writing Zig code for the standard library. label Jul 2, 2019
@andrewrk andrewrk modified the milestones: 0.5.0, 0.6.0 Jul 2, 2019
@andrewrk andrewrk added the enhancement Solving this issue will likely involve adding new logic or components to the codebase. label Jul 2, 2019
@andrewrk andrewrk changed the title stack traces don't work when there is a stack overflow in debug builds, detect stack overflow at runtime and output a partial stack trace Jul 2, 2019
@andrewrk andrewrk modified the milestones: 0.6.0, 0.7.0 Jan 3, 2020
@andrewrk andrewrk modified the milestones: 0.7.0, 0.8.0 Oct 9, 2020
@andrewrk andrewrk modified the milestones: 0.8.0, 0.9.0 Nov 6, 2020
@andrewrk andrewrk modified the milestones: 0.9.0, 0.10.0 May 19, 2021
@mlugg mlugg added this to Safety Aug 22, 2024
@mlugg mlugg moved this to To do in Safety Aug 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Solving this issue will likely involve adding new logic or components to the codebase. standard library This issue involves writing Zig code for the standard library.
Projects
Status: To do
Development

No branches or pull requests

1 participant