Skip to content

Commit dc43fb4

Browse files
committed
Set Cranelift backend flag in benchmarks
1 parent e0f9826 commit dc43fb4

File tree

1 file changed

+8
-0
lines changed
  • collector/src/compile/execute

1 file changed

+8
-0
lines changed

collector/src/compile/execute/mod.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -262,6 +262,14 @@ impl<'a> CargoProcess<'a> {
262262
cmd.arg("-Ztimings");
263263
}
264264
cmd.arg("--");
265+
266+
match self.backend {
267+
CodegenBackend::Llvm => {}
268+
CodegenBackend::Cranelift => {
269+
cmd.arg("-Zcodegen-backend=cranelift");
270+
}
271+
}
272+
265273
// --wrap-rustc-with is not a valid rustc flag. But rustc-fake
266274
// recognizes it, strips it (and its argument) out, and uses it as an
267275
// indicator that the rustc invocation should be profiled. This works

0 commit comments

Comments
 (0)