We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4ce50a3 commit d7f1656Copy full SHA for d7f1656
src/tools/miri/src/bin/miri.rs
@@ -723,10 +723,9 @@ fn main() {
723
724
// Ensure we have parallelism for many-seeds mode.
725
if many_seeds.is_some() && !rustc_args.iter().any(|arg| arg.starts_with("-Zthreads=")) {
726
- rustc_args.push(format!(
727
- "-Zthreads={}",
728
- std::thread::available_parallelism().map_or(1, |n| n.get())
729
- ));
+ // Clamp to 8 threads; things get a lot less efficient beyond that due to lock contention.
+ let threads = std::thread::available_parallelism().map_or(1, |n| n.get()).min(8);
+ rustc_args.push(format!("-Zthreads={threads}"));
730
}
731
let many_seeds =
732
many_seeds.map(|seeds| ManySeedsConfig { seeds, keep_going: many_seeds_keep_going });
0 commit comments