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
out of memory #124901
Comments
|
This gave an error back in 1.76:
|
Infinite recursion from
Since |
Bisection points to fb4bca0 (but unsure if directly related) cc @reitermarkus @dtolnay bisected with cargo-bisect-rustc v0.6.8Host triple: x86_64-unknown-linux-gnu cargo bisect-rustc --without-cargo --preserve --start 1.76.0 --end 1.77.0 --timeout 2 --script test.sh |
WG-prioritization assigning priority (Zulip discussion). @rustbot label -I-prioritize +P-medium |
This frame is suspicious, since the code around it is already trying to avoid infinite recursion:
rust/compiler/rustc_query_impl/src/plumbing.rs Lines 328 to 334 in cf77474
cc @Zoxc who added that I think maybe it should set the reduced state here, e.g. this seems to work: diff --git a/compiler/rustc_query_impl/src/plumbing.rs b/compiler/rustc_query_impl/src/plumbing.rs
index a7696b1fbaff..7a9a1fafc579 100644
--- a/compiler/rustc_query_impl/src/plumbing.rs
+++ b/compiler/rustc_query_impl/src/plumbing.rs
@@ -330,7 +330,7 @@ pub(crate) fn create_query_frame<
// so exit to avoid infinite recursion.
None
} else {
- Some(key.default_span(tcx))
+ Some(ty::print::with_reduced_queries!(key.default_span(tcx)))
};
let def_id = key.key_as_def_id();
let def_kind = if kind == dep_graph::dep_kinds::def_kind || reduce_queries { |
I don't immediately spot why there's a cycle from the limited backtrace or why the check for |
Here's a full backtrace. I was breaking on each Click to expand
|
Unfortunately there is no kind of error or warning given by rustc, it just OOMs right away :/
I tried this code:
I expected to see this happen: explanation
Instead, this happened: explanation
Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: