parallel compiler: unconditional panic Resource temporarily unavailable
when limiting max memory
#115021
Labels
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
WG-compiler-parallel
Working group: Parallelizing the compiler
I use
prlimit
to limit the amount of memory that rustc can use to protect myself against OOMs.It looks like with the parallel compiler, something might unconditionally check that
threads * x
amount of memory is available, even if rustc would never exhaust the given limit of memory it can take.repro: I built with parrallel_compiler and debug assertions.
run:
prlimit and limit memory to around 3 gb, run rustc with ~100 threads, no actual file needed:
prlimit --noheadings --as=3076000000 --cpu=300 /home/matthias/.rustup/toolchains/local-debug-assertions/bin/rustc -Zthreads=100
The text was updated successfully, but these errors were encountered: