about summary refs log tree commit diff
path: root/src/ci/docker
diff options
context:
space:
mode:
authorBen Kimock <kimockb@gmail.com>2023-11-17 21:05:11 -0500
committerBen Kimock <kimockb@gmail.com>2023-11-20 09:36:40 -0500
commit9ada6544f64fb85d9f0ffa54f1f5fa4ea3731df9 (patch)
treef841f07cc4b3749918a3221c3e6381da2a8b5b49 /src/ci/docker
parentb99165842df821a4f067ff20d8119c53fc6d54f6 (diff)
downloadrust-9ada6544f64fb85d9f0ffa54f1f5fa4ea3731df9.tar.gz
rust-9ada6544f64fb85d9f0ffa54f1f5fa4ea3731df9.zip
Test with -Zmiri-provenance-gc=1 on Linux
Diffstat (limited to 'src/ci/docker')
-rwxr-xr-xsrc/ci/docker/host-x86_64/x86_64-gnu-tools/checktools.sh11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/ci/docker/host-x86_64/x86_64-gnu-tools/checktools.sh b/src/ci/docker/host-x86_64/x86_64-gnu-tools/checktools.sh
index 821a09feb2d..205ee263217 100755
--- a/src/ci/docker/host-x86_64/x86_64-gnu-tools/checktools.sh
+++ b/src/ci/docker/host-x86_64/x86_64-gnu-tools/checktools.sh
@@ -25,7 +25,16 @@ cat /tmp/toolstate/toolstates.json
 python3 "$X_PY" test --stage 2 check-tools
 python3 "$X_PY" test --stage 2 src/tools/clippy
 python3 "$X_PY" test --stage 2 src/tools/rustfmt
-python3 "$X_PY" test --stage 2 src/tools/miri
+
+# Testing Miri is a bit more complicated.
+# We set the GC interval to the shortest possible value (0 would be off) to increase the chance
+# that bugs which only surface when the GC runs at a specific time are more likely to cause CI to fail.
+# This significantly increases the runtime of our test suite, or we'd do this in PR CI too.
+if [[ -z "${PR_CI_JOB:-}" ]]; then
+    MIRIFLAGS=-Zmiri-provenance-gc=1 python3 "$X_PY" test --stage 2 src/tools/miri
+else
+    python3 "$X_PY" test --stage 2 src/tools/miri
+fi
 # We natively run this script on x86_64-unknown-linux-gnu and x86_64-pc-windows-msvc.
 # Also cover some other targets via cross-testing, in particular all tier 1 targets.
 export BOOTSTRAP_SKIP_TARGET_SANITY=1 # we don't need `cc` for these targets