Skip to content

Commit

Permalink
Rollup merge of #123373 - onur-ozkan:skip-codegen, r=Mark-Simulacrum
Browse files Browse the repository at this point in the history
skip Codegen{GCC,Cranelift} when using CI rustc

CI rustc uses the default codegen backend, therefore we can't run `CodegenGCC` and `CodegenCranelift` tests when using it.

cc `@bjorn3` (to make sure I am not doing anything wrong)

Fixes #123331
  • Loading branch information
GuillaumeGomez committed Apr 14, 2024
2 parents fa483a4 + 167e3ab commit f3a68fb
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/bootstrap/src/core/build_steps/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3300,6 +3300,11 @@ impl Step for CodegenCranelift {
return;
}

if builder.download_rustc() {
builder.info("CI rustc uses the default codegen backend. skipping");
return;
}

if !target_supports_cranelift_backend(run.target) {
builder.info("target not supported by rustc_codegen_cranelift. skipping");
return;
Expand Down Expand Up @@ -3421,6 +3426,11 @@ impl Step for CodegenGCC {
return;
}

if builder.download_rustc() {
builder.info("CI rustc uses the default codegen backend. skipping");
return;
}

let triple = run.target.triple;
let target_supported =
if triple.contains("linux") { triple.contains("x86_64") } else { false };
Expand Down

0 comments on commit f3a68fb

Please sign in to comment.