mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-29 20:46:07 +03:00
maintaining special list of targets which need different execution command
This commit is contained in:
committed by
Amanieu d'Antras
parent
e15d6fae92
commit
8e269afcfe
@@ -2,6 +2,8 @@
|
||||
use rayon::prelude::*;
|
||||
use std::process::Command;
|
||||
|
||||
static SPECIAL_TARGETS: [&str; 1] = ["aarch64_be-unknown-linux-gnu"];
|
||||
|
||||
pub fn compare_outputs(
|
||||
intrinsic_name_list: &Vec<String>,
|
||||
toolchain: &str,
|
||||
@@ -16,7 +18,18 @@ pub fn compare_outputs(
|
||||
.arg(format!("{runner} ./c_programs/{intrinsic_name}"))
|
||||
.output();
|
||||
|
||||
let rust = if target != "aarch64_be-unknown-linux-gnu" {
|
||||
let rust = if SPECIAL_TARGETS
|
||||
.into_iter()
|
||||
.find(|&special_target| special_target == target)
|
||||
.is_some()
|
||||
{
|
||||
Command::new("sh")
|
||||
.arg("-c")
|
||||
.arg(format!(
|
||||
"{runner} ./rust_programs/target/{target}/release/{intrinsic_name}",
|
||||
))
|
||||
.output()
|
||||
} else {
|
||||
Command::new("sh")
|
||||
.current_dir("rust_programs")
|
||||
.arg("-c")
|
||||
@@ -25,13 +38,6 @@ pub fn compare_outputs(
|
||||
))
|
||||
.env("RUSTFLAGS", "-Cdebuginfo=0")
|
||||
.output()
|
||||
} else {
|
||||
Command::new("sh")
|
||||
.arg("-c")
|
||||
.arg(format!(
|
||||
"{runner} ./rust_programs/target/{target}/release/{intrinsic_name}",
|
||||
))
|
||||
.output()
|
||||
};
|
||||
|
||||
let (c, rust) = match (c, rust) {
|
||||
|
||||
Reference in New Issue
Block a user