Skip to content

Commit ce97b57

Browse files
Save time by running NLL only on check builds
1 parent 5a455cd commit ce97b57

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

collector/src/bin/rustc-perf-collector/execute.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,12 @@ impl Benchmark {
673673
}
674674

675675
// A full non-incremental build with NLL enabled.
676-
if run_kinds.contains(&RunKind::Nll) && self.config.nll {
676+
// These are only collected on check builds to save time.
677+
let has_check = build_kinds.contains(&BuildKind::Check);
678+
let is_check = build_kind == BuildKind::Check;
679+
if run_kinds.contains(&RunKind::Nll) && self.config.nll &&
680+
((has_check && is_check) || !has_check)
681+
{
677682
self.mk_cargo_process(rustc_path, cargo_path, cwd, build_kind)
678683
.nll(true)
679684
.processor(processor, &self.name, RunKind::Nll, "Nll", None)

0 commit comments

Comments
 (0)