Skip to content

Commit 9031124

Browse files
sbryngelsonclaude
andcommitted
Clean stale build artifacts at start of every CI job
Self-hosted runners have persistent workspaces that accumulate build artifacts across CI runs. When different compiler configs (e.g. gfortran vs NVHPC) run on the same runner, stale LAPACK/dependency libraries compiled by the wrong compiler cause linker failures. git clean -ffdx often fails on the shared scratch filesystem (could not lstat errors), leaving the contaminated artifacts in place. Fix by running ./mfc.sh clean proactively at the start of every job (Phoenix test/bench, Frontier CCE/AMD build), not just on retry. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent cf4a9d0 commit 9031124

4 files changed

Lines changed: 14 additions & 0 deletions

File tree

.github/workflows/frontier/build.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ fi
2020

2121
. ./mfc.sh load -c f -m g
2222

23+
# Clean stale build artifacts from previous CI runs
24+
./mfc.sh clean
25+
2326
if [ "$run_bench" == "bench" ]; then
2427
for dir in benchmarks/*/; do
2528
./mfc.sh run -v "$dir/case.py" --case-optimization -j 4 --dry-run $build_opts

.github/workflows/frontier_amd/build.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ fi
2020

2121
. ./mfc.sh load -c famd -m g
2222

23+
# Clean stale build artifacts from previous CI runs
24+
./mfc.sh clean
25+
2326
if [ "$run_bench" == "bench" ]; then
2427
for dir in benchmarks/*/; do
2528
./mfc.sh run -v "$dir/case.py" --case-optimization -j 4 --dry-run $build_opts

.github/workflows/phoenix/bench.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
#!/bin/bash
22

3+
# Clean stale build artifacts from previous CI runs to prevent
4+
# cross-compiler contamination (e.g. gfortran LAPACK linked by NVHPC)
5+
./mfc.sh clean
6+
37
n_ranks=12
48

59
echo "My interface is:" $job_interface

.github/workflows/phoenix/test.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
#!/bin/bash
22

3+
# Clean stale build artifacts from previous CI runs to prevent
4+
# cross-compiler contamination (e.g. gfortran LAPACK linked by NVHPC)
5+
./mfc.sh clean
6+
37
build_opts=""
48
if [ "$job_device" = "gpu" ]; then
59
build_opts="--gpu"

0 commit comments

Comments
 (0)