-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
rustc hangs and takes increasing amounts of memory when compiling json
crate as dependency
#89647
Comments
This might be the same bug as in #89524, I see the same sort of behavior. I need to be compiling Also interesting that we're both seeing this related to parsing crates. I wonder if there's something about them that makes whatever pattern is present more likely. |
Do you think this set of issues could be considered a NewPM (I'm assuming it's NewPM-related) blocker? |
Looks like this regression is now on stable 1.59. @apiraino sorry, I missed the notification back then; but I didn't investigate this further. (I also don't know how to pass |
Summarizing here (for SEO purposes) from the linked issues the mitigating flags that make the issue disappear: setting the release build profile [profile.release]
panic = "abort"
+opt-level = 0 # or 2 or disabling the new LLVM pass manager altogether:
|
It looks like ruffle switched away from |
This is supposed to be fixed by #94764, but as mentioned above, I already couldn't reproduce this on nightly before that, so I can't verify whether this specific instance of the problem has been addressed. If someone still sees hangs with the new pass manager, please let me know. |
Reproduction:
cd web
cargo build --release --verbose -j1 --target=wasm32-unknown-unknown
Result: under a minute into the build, the compiler hangs when compiling the
json
dependency, taking increasingly more memory; after 40s it spiked to 1GB, then 2GB and more. Thejson
crate is tiny with no dependencies of its own, normally it should take <5s to build.Weirdly, I cannot reproduce it when building the
json
crate's repo on its own, but I may be missing some build configuration difference.Reproduced on builds starting with
nightly-2021-09-26
(rustc 1.57.0-nightly (addb4da68 2021-09-25)
), it works fine on earlier build. Also someone else managed to reproduce this on latest nightly too.The text was updated successfully, but these errors were encountered: