Skip to content

Commit c7155bc

Browse files
Merge pull request swiftlang#30408 from adrian-prantl/build-script-linux-fixup
build-script: Avoid re-runnning the entire LLDB test suite twice.
2 parents afc8762 + 7d69912 commit c7155bc

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

utils/build-script-impl

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2344,8 +2344,10 @@ for host in "${ALL_HOSTS[@]}"; do
23442344
LLVM_LIT_ARGS="${LLVM_LIT_ARGS} -j $(sysctl hw.physicalcpu | awk -v N=${BUILD_JOBS} '{ print (N < $2) ? N : $2 }')"
23452345
fi
23462346

2347+
FILTER_SWIFT_OPTION="--filter=[sS]wift"
2348+
LLVM_LIT_FILTER_ARG=""
23472349
if [[ "$(true_false ${LLDB_TEST_SWIFT_ONLY})" == "TRUE" ]]; then
2348-
LLVM_LIT_ARGS="${LLVM_LIT_ARGS} --filter=[sS]wift"
2350+
LLVM_LIT_FILTER_ARG="${FILTER_SWIFT_OPTION}"
23492351
fi
23502352

23512353
# Record the times test took and report the slowest.
@@ -2354,19 +2356,18 @@ for host in "${ALL_HOSTS[@]}"; do
23542356
echo "--- Running LLDB unit tests ---"
23552357
with_pushd ${lldb_build_dir} \
23562358
call ${NINJA_BIN} -j ${BUILD_JOBS} unittests/LLDBUnitTests
2357-
echo "--- Running LLDB Swift tests (ClangImporter) ---"
2359+
echo "--- Running LLDB tests (Swift tests using ClangImporter) ---"
23582360
with_pushd ${lldb_build_dir} \
23592361
call ${NINJA_BIN} -j ${BUILD_JOBS} lldb-test-deps
23602362
with_pushd ${results_dir} \
23612363
call "${llvm_build_dir}/bin/llvm-lit" \
23622364
"${lldb_build_dir}/test" \
2363-
${LLVM_LIT_ARGS}
2364-
# Rerun the tests with DWARFImporter only.
2365-
echo "--- Running LLDB Swift tests (DWARFImporter) ---"
2365+
${LLVM_LIT_ARGS} ${LLVM_LIT_FILTER_ARG}
2366+
echo "--- Rerun LLDB Swift tests (using only DWARFImporter) ---"
23662367
with_pushd ${results_dir} \
23672368
call "${llvm_build_dir}/bin/llvm-lit" \
23682369
"${lldb_build_dir}/test" \
2369-
${LLVM_LIT_ARGS} \
2370+
${LLVM_LIT_ARGS} ${FILTER_SWIFT_OPTION} \
23702371
--param dotest-args="--setting symbols.use-swift-clangimporter=false"
23712372

23722373
if [[ -x "${LLDB_TEST_SWIFT_COMPATIBILITY}" ]] ; then

0 commit comments

Comments
 (0)