From 14e50f46c507663c12afd025ae5f3298e22b3e49 Mon Sep 17 00:00:00 2001
From: Jubilee Young <workingjubilee@gmail.com>
Date: Thu, 23 Jan 2025 15:59:41 -0800
Subject: [PATCH 1/2] ci: Remove the power to skip tests from opt-dist

---
 src/tools/opt-dist/src/environment.rs |  6 ------
 src/tools/opt-dist/src/main.rs        | 24 ------------------------
 src/tools/opt-dist/src/tests.rs       |  5 +----
 3 files changed, 1 insertion(+), 34 deletions(-)

diff --git a/src/tools/opt-dist/src/environment.rs b/src/tools/opt-dist/src/environment.rs
index 90d0ca717b25c..143aff098e86c 100644
--- a/src/tools/opt-dist/src/environment.rs
+++ b/src/tools/opt-dist/src/environment.rs
@@ -15,8 +15,6 @@ pub struct Environment {
     artifact_dir: Utf8PathBuf,
     /// Path to the host LLVM used to compile LLVM in `src/llvm-project`.
     host_llvm_dir: Utf8PathBuf,
-    /// List of test paths that should be skipped when testing the optimized artifacts.
-    skipped_tests: Vec<String>,
     /// Arguments passed to `rustc-perf --cargo-config <value>` when running benchmarks.
     #[builder(default)]
     benchmark_cargo_config: Vec<String>,
@@ -94,10 +92,6 @@ impl Environment {
         self.shared_llvm
     }
 
-    pub fn skipped_tests(&self) -> &[String] {
-        &self.skipped_tests
-    }
-
     pub fn benchmark_cargo_config(&self) -> &[String] {
         &self.benchmark_cargo_config
     }
diff --git a/src/tools/opt-dist/src/main.rs b/src/tools/opt-dist/src/main.rs
index aa05b5f0e76ca..1d544c4dd7f18 100644
--- a/src/tools/opt-dist/src/main.rs
+++ b/src/tools/opt-dist/src/main.rs
@@ -84,10 +84,6 @@ enum EnvironmentCmd {
         #[arg(long, default_value_t = false)]
         use_bolt: bool,
 
-        /// Tests that should be skipped when testing the optimized compiler.
-        #[arg(long)]
-        skipped_tests: Vec<String>,
-
         #[clap(flatten)]
         shared: SharedArgs,
 
@@ -122,7 +118,6 @@ fn create_environment(args: Args) -> anyhow::Result<(Environment, Vec<String>)>
             rustc_perf_checkout_dir,
             llvm_shared,
             use_bolt,
-            skipped_tests,
             benchmark_cargo_config,
             shared,
         } => {
@@ -136,7 +131,6 @@ fn create_environment(args: Args) -> anyhow::Result<(Environment, Vec<String>)>
                 .prebuilt_rustc_perf(rustc_perf_checkout_dir)
                 .shared_llvm(llvm_shared)
                 .use_bolt(use_bolt)
-                .skipped_tests(skipped_tests)
                 .benchmark_cargo_config(benchmark_cargo_config)
                 .build()?;
 
@@ -148,19 +142,6 @@ fn create_environment(args: Args) -> anyhow::Result<(Environment, Vec<String>)>
 
             let is_aarch64 = target_triple.starts_with("aarch64");
 
-            let mut skip_tests = vec![
-                // Fails because of linker errors, as of June 2023.
-                "tests/ui/process/nofile-limit.rs".to_string(),
-            ];
-
-            if is_aarch64 {
-                skip_tests.extend([
-                    // Those tests fail only inside of Docker on aarch64, as of December 2024
-                    "tests/ui/consts/promoted_running_out_of_memory_issue-130687.rs".to_string(),
-                    "tests/ui/consts/large_const_alloc.rs".to_string(),
-                ]);
-            }
-
             let checkout_dir = Utf8PathBuf::from("/checkout");
             let env = EnvironmentBuilder::default()
                 .host_tuple(target_triple)
@@ -172,7 +153,6 @@ fn create_environment(args: Args) -> anyhow::Result<(Environment, Vec<String>)>
                 .shared_llvm(true)
                 // FIXME: Enable bolt for aarch64 once it's fixed upstream. Broken as of December 2024.
                 .use_bolt(!is_aarch64)
-                .skipped_tests(skip_tests)
                 .build()?;
 
             (env, shared.build_args)
@@ -191,10 +171,6 @@ fn create_environment(args: Args) -> anyhow::Result<(Environment, Vec<String>)>
                 .build_dir(checkout_dir)
                 .shared_llvm(false)
                 .use_bolt(false)
-                .skipped_tests(vec![
-                    // Fails as of June 2023.
-                    "tests\\codegen\\vec-shrink-panik.rs".to_string(),
-                ])
                 .build()?;
 
             (env, shared.build_args)
diff --git a/src/tools/opt-dist/src/tests.rs b/src/tools/opt-dist/src/tests.rs
index 8b3bd77141ba8..d2af813f65550 100644
--- a/src/tools/opt-dist/src/tests.rs
+++ b/src/tools/opt-dist/src/tests.rs
@@ -89,7 +89,7 @@ llvm-config = "{llvm_config}"
     std::fs::write("config.toml", config_content)?;
 
     let x_py = env.checkout_path().join("x.py");
-    let mut args = vec![
+    let args = vec![
         env.python_binary(),
         x_py.as_str(),
         "test",
@@ -107,9 +107,6 @@ llvm-config = "{llvm_config}"
         "tests/ui",
         "tests/crashes",
     ];
-    for test_path in env.skipped_tests() {
-        args.extend(["--skip", test_path]);
-    }
     cmd(&args)
         .env("COMPILETEST_FORCE_STAGE0", "1")
         // Also run dist-only tests

From ac37d7cffc745f815c41b1c1dfd3954354388da1 Mon Sep 17 00:00:00 2001
From: Jubilee Young <workingjubilee@gmail.com>
Date: Thu, 23 Jan 2025 21:52:15 -0800
Subject: [PATCH 2/2] DIST_TRY_BUILD strikes again

---
 src/ci/github-actions/jobs.yml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/ci/github-actions/jobs.yml b/src/ci/github-actions/jobs.yml
index 5e95e3721dfd2..37732679d7edc 100644
--- a/src/ci/github-actions/jobs.yml
+++ b/src/ci/github-actions/jobs.yml
@@ -84,8 +84,8 @@ envs:
     #   builds)
     # - not running `opt-dist`'s post-optimization smoke tests on the resulting toolchain
     #
-    # If you *want* these to happen however, temporarily uncomment it before triggering a try build.
-    DIST_TRY_BUILD: 1
+    # If you *want* these to happen however, temporarily comment it before triggering a try build.
+    # DIST_TRY_BUILD: 1
 
   auto:
     <<: *production