diff --git a/CHANGELOG.md b/CHANGELOG.md index 7c5c195d..cbe3cfd0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,8 @@ Note: In this file, do not use the hard wrap in the middle of a sentence for com ## [Unreleased] +- Limit the number of test threads to work around [rust-lang/rust#91092](https://github.com/rust-lang/rust/issues/91092). ([#184](https://github.com/taiki-e/cargo-llvm-cov/pull/184)) + ## [0.4.5] - 2022-06-02 - Fix handling of `RUSTC_WRAPPER`, `RUSTC`, and similar environment variables and configs. ([#180](https://github.com/taiki-e/cargo-llvm-cov/pull/180)) diff --git a/src/main.rs b/src/main.rs index b13da4dd..371984eb 100644 --- a/src/main.rs +++ b/src/main.rs @@ -294,6 +294,8 @@ fn set_env(cx: &Context, target: &mut impl EnvTarget) { } target.set("LLVM_PROFILE_FILE", llvm_profile_file.as_str()); target.set("CARGO_INCREMENTAL", "0"); + // Workaround for https://github.com/rust-lang/rust/issues/91092 + target.set("RUST_TEST_THREADS", "1"); } fn has_z_flag(args: &Args, name: &str) -> bool {