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
Intermittent stack overflow on mac debug compiling cssparser without dummy_match_byte. #21038
Comments
cc @Eijebong, did you ever figure out what was up with that? Given the stack I suspect just Syn's using a lot of stack due to lack of inlining but... Also, no idea why the stack overflows would be intermittent. |
We never figured out what was going on, we set the stack size to 128MB in cssparser's build script and it didn't fix it... |
So, what the hell, there's a |
Tried servo/rust-cssparser#224 on #21036 and looks it was green, so I'm moderately sure that is the root cause. |
procedural-masquerade: Give more stack to procedural-masquerade macros. This is a prospective fix for servo/servo#21038. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/rust-cssparser/224) <!-- Reviewable:end -->
This stacktrace looks quite bad to me, is it expected that syn produces call stacks that deep @dtolnay? |
Thanks for the ping. It looks like this is a consequence of the way we handle precedence of different kinds of expressions. We should be able to do better. I filed dtolnay/syn#442 to follow up. |
Here's the suspected backtrace (that is, the backtrace of the first stack overflow that I managed to reproduce locally playing with the thread stack size:
I've verified that the culprit is this match_byte! expansion:
https://github.com/servo/rust-cssparser/blob/ad39746d6b2efab00ac9b3126e89fb7e5a89392d/src/tokenizer.rs#L814
We should try to re-enable the feature sooner rather than later.
The text was updated successfully, but these errors were encountered: