stack overflow from do_mir_borrowck() when building tinyvec 1.X #79438
Labels
A-borrow-checker
Area: The borrow checker
C-bug
Category: This is a bug.
I-crash
Issue: The compiler crashes (SIGSEGV, SIGABRT, etc). Use I-ICE instead when the compiler panics.
T-release
Relevant to the release subteam, which will review and decide on the PR/issue.
I have a reproducible stack overflow when trying to build versions of
tinyvec
as of this commit on illumos systems. The output is terse, reporting a SIGSEGV instead of an overflow, but I have verified by looking at the generated core file that it is indeed overflowing a (manually allocated) stack.Meta
I am running
1.48.0
stablerustc
, built by the official project CI/CD:Notably, this appears to have been fixed in the current beta; i.e.,
I tried setting
RUST_BACKTRACE
in the environment, but that did not appear to result in the printing of a backtrace; merely the same message as before:Analysis
I ran the command that
cargo
reported as failed under the debugger so that I could extract some information:This is thread 2, which has an official thread stack starting at
0xfffffc7fed000000
and extending down to0xfffffc7fec800000
:Note that
ensure_sufficient_stack()
allocates its own stack and arranges viastacker
to begin executing new calls on that stack, so after therust_psm_on_stack()
frame we are on the bonus stack, which appears to have a size of ~1MB:And, indeed, the top frame as we SIGSEGV is quite close to the top of the bonus stack:
Request
Because this appears to be fixed in the beta release, I had a look to see if I could find a relevant commit. Indeed, this one seems to fit the bill: af72a70 (PR #78607).
Is there a process to get this backported to the stable branch, 1.48? This failure appears to make it difficult or impossible to build things that use tinyvec (such as, transitively, anything that uses reqwest) with the current stable toolchain for us.
The text was updated successfully, but these errors were encountered: