1.95 beta regression: stack overflow inside parser
Open
Nobody has claimed this yet.
A-parser
C-bug
E-needs-bisection
I-crash
P-medium
regression-from-stable-to-stable
S-has-mcve
T-compiler
- Dominant language
- Rust
- Stars
- 119k
- Forks
- 16.1k
- PR merge metrics
- PR metrics pending
Description
Regression found by the 1.95 beta crater run.
[INFO] [stderr] error: rustc interrupted by SIGSEGV, printing backtrace
[INFO] [stderr]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x3b6096c)[0x7aeebb56096c]
[INFO] [stderr] /lib/x86_64-linux-gnu/libc.so.6(+0x45330)[0x7aeeb7833330]
[INFO] [stderr] /lib/x86_64-linux-gnu/libc.so.6(pthread_mutex_trylock+0xc)[0x7aeeb788eefc]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/bin/rustc(+0x24d7f)[0x6307552fbd7f]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/bin/rustc(+0x14b54)[0x6307552ebb54]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x5480d10)[0x7aeebce80d10]
[INFO] [stderr]
[INFO] [stderr] ### cycle encountered after 6 frames with period 10
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(_RNvMNtNtCs1gAZ6foNq5q_11rustc_parse6parser4exprNtB4_6Parser21parse_expr_assoc_with+0x45)[0x7aeebce79d85]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x54261b0)[0x7aeebce261b0]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(_RNvMNtNtCs1gAZ6foNq5q_11rustc_parse6parser4stmtNtB4_6Parser27parse_stmt_without_recovery+0xd46)[0x7aeebce3ac5e]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x5442772)[0x7aeebce42772]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x5481149)[0x7aeebce81149]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(_RNvMNtNtCs1gAZ6foNq5q_11rustc_parse6parser4exprNtB4_6Parser21parse_expr_assoc_with+0x45)[0x7aeebce79d85]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x54261b0)[0x7aeebce261b0]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(_RNvMNtNtCs1gAZ6foNq5q_11rustc_parse6parser4stmtNtB4_6Parser27parse_stmt_without_recovery+0xd46)[0x7aeebce3ac5e]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x5442772)[0x7aeebce42772]
[INFO] [stderr] /opt/rustwide/rustup-home/toolchains/1.95.0-beta.3-x86_64-unknown-linux-gnu/lib/librustc_driver-c1a4ee0be8fb5b4c.so(+0x5481149)[0x7aeebce81149]
[INFO] [stderr] ### recursed 25 times
[INFO] [stderr]
[INFO] [stderr]
[INFO] [stderr] note: rustc unexpectedly overflowed its stack! this is a bug
[INFO] [stderr] note: maximum backtrace depth reached, frames may have been lost
[INFO] [stderr] note: we would appreciate a report at https://github.com/rust-lang/rust
[INFO] [stderr] help: you can increase rustc's stack size by setting RUST_MIN_STACK=16777216
[INFO] [stderr] note: backtrace dumped due to SIGSEGV! resuming signal
[INFO] [stderr] error: could not compile `rmk-types` (lib)
https://crater-reports.s3.amazonaws.com/beta-1.95-3/1.95.0-beta.3/reg/rmk-types-0.2.2/log.txt
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked crater log for rmk-types 0.2.2 and reproduce the failure with Rust 1.95.0-beta.3. Trace the parser entry points named in the backtrace, especially Parser::parse_expr_assoc_with and Parser::parse_stmt_without_recovery. Done means the crate no longer causes rustc to overflow its stack during parsing, with a regression case covering the failure.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100