Skip to content

Commit 20ca119

Browse files
committed
[libc++][NFC] Refactor run-buildbot to make it closer to our buildkite pipeline
Differential Revision: https://reviews.llvm.org/D138380
1 parent 35df882 commit 20ca119

File tree

1 file changed

+80
-62
lines changed

1 file changed

+80
-62
lines changed

libcxx/utils/ci/run-buildbot

Lines changed: 80 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,9 @@ check-generated-output)
202202
# Reject code with trailing whitespace
203203
! grep -rn '[[:blank:]]$' libcxx/include libcxx/src libcxx/test libcxx/benchmarks || false
204204
;;
205+
#
206+
# Various Standard modes
207+
#
205208
generic-cxx03)
206209
clean
207210
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-cxx03.cmake"
@@ -238,43 +241,9 @@ generic-cxx2b)
238241
check-runtimes
239242
check-abi-list
240243
;;
241-
generic-assertions)
242-
clean
243-
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-assertions.cmake"
244-
check-runtimes
245-
check-abi-list
246-
;;
247-
generic-debug-mode)
248-
clean
249-
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-debug-mode.cmake"
250-
check-runtimes
251-
# We don't check the ABI lists because the debug mode ABI is not stable
252-
;;
253-
generic-noexceptions)
254-
clean
255-
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-noexceptions.cmake"
256-
check-runtimes
257-
check-abi-list
258-
;;
259-
generic-modules)
260-
clean
261-
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-modules.cmake"
262-
check-runtimes
263-
check-abi-list
264-
;;
265-
generic-static)
266-
clean
267-
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-static.cmake"
268-
check-runtimes
269-
;;
270-
generic-merged)
271-
clean
272-
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-merged.cmake" \
273-
-DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \
274-
-DLIBCXXABI_TEST_CONFIG="llvm-libc++abi-merged.cfg.in" \
275-
-DLIBUNWIND_TEST_CONFIG="llvm-libunwind-merged.cfg.in"
276-
check-runtimes
277-
;;
244+
#
245+
# Other compiler support
246+
#
278247
generic-gcc)
279248
clean
280249
generate-cmake -DLIBCXX_ENABLE_WERROR=NO \
@@ -290,6 +259,9 @@ generic-gcc-cxx11)
290259
-DLIBUNWIND_ENABLE_WERROR=NO
291260
check-runtimes
292261
;;
262+
#
263+
# Sanitizers
264+
#
293265
generic-asan)
294266
clean
295267
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-asan.cmake"
@@ -310,16 +282,76 @@ generic-ubsan)
310282
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-ubsan.cmake"
311283
check-runtimes
312284
;;
313-
generic-with_llvm_unwinder)
285+
#
286+
# Various build configurations
287+
#
288+
bootstrapping-build)
314289
clean
315-
generate-cmake -DLIBCXXABI_USE_LLVM_UNWINDER=ON
290+
291+
echo "--- Generating CMake"
292+
${CMAKE} \
293+
-S "${MONOREPO_ROOT}/llvm" \
294+
-B "${BUILD_DIR}" \
295+
-GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \
296+
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
297+
-DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \
298+
-DLLVM_ENABLE_PROJECTS="clang" \
299+
-DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi;libunwind" \
300+
-DLLVM_RUNTIME_TARGETS="$(c++ --print-target-triple)" \
301+
-DLLVM_TARGETS_TO_BUILD="host" \
302+
-DRUNTIMES_BUILD_ALLOW_DARWIN=ON \
303+
-DLLVM_ENABLE_ASSERTIONS=ON
304+
305+
echo "+++ Running the libc++ and libc++abi tests"
306+
${NINJA} -C "${BUILD_DIR}" check-runtimes
307+
308+
echo "--- Installing libc++ and libc++abi to a fake location"
309+
${NINJA} -C "${BUILD_DIR}" install-runtimes
310+
;;
311+
generic-static)
312+
clean
313+
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-static.cmake"
314+
check-runtimes
315+
;;
316+
generic-merged)
317+
clean
318+
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-merged.cmake" \
319+
-DLIBCXX_TEST_CONFIG="llvm-libc++-shared.cfg.in" \
320+
-DLIBCXXABI_TEST_CONFIG="llvm-libc++abi-merged.cfg.in" \
321+
-DLIBUNWIND_TEST_CONFIG="llvm-libunwind-merged.cfg.in"
322+
check-runtimes
323+
;;
324+
generic-assertions)
325+
clean
326+
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-assertions.cmake"
316327
check-runtimes
328+
check-abi-list
329+
;;
330+
generic-debug-mode)
331+
clean
332+
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-debug-mode.cmake"
333+
check-runtimes
334+
# We don't check the ABI lists because the debug mode ABI is not stable
317335
;;
318336
generic-no-transitive-includes)
319337
clean
320338
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-transitive-includes.cmake"
321339
check-runtimes
322340
;;
341+
generic-with_llvm_unwinder)
342+
clean
343+
generate-cmake -DLIBCXXABI_USE_LLVM_UNWINDER=ON
344+
check-runtimes
345+
;;
346+
generic-modules)
347+
clean
348+
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-modules.cmake"
349+
check-runtimes
350+
check-abi-list
351+
;;
352+
#
353+
# Parts removed
354+
#
323355
generic-no-threads)
324356
clean
325357
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-no-threads.cmake"
@@ -361,6 +393,15 @@ generic-no-experimental)
361393
check-runtimes
362394
check-abi-list
363395
;;
396+
generic-noexceptions)
397+
clean
398+
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-noexceptions.cmake"
399+
check-runtimes
400+
check-abi-list
401+
;;
402+
#
403+
# Other miscellaneous jobs
404+
#
364405
generic-abi-unstable)
365406
clean
366407
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/Generic-abi-unstable.cmake"
@@ -477,29 +518,6 @@ documentation)
477518
echo "+++ Generating documentation"
478519
${NINJA} -vC "${BUILD_DIR}" docs-libcxx-html
479520
;;
480-
bootstrapping-build)
481-
clean
482-
483-
echo "--- Generating CMake"
484-
${CMAKE} \
485-
-S "${MONOREPO_ROOT}/llvm" \
486-
-B "${BUILD_DIR}" \
487-
-GNinja -DCMAKE_MAKE_PROGRAM="${NINJA}" \
488-
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
489-
-DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}" \
490-
-DLLVM_ENABLE_PROJECTS="clang" \
491-
-DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi;libunwind" \
492-
-DLLVM_RUNTIME_TARGETS="$(c++ --print-target-triple)" \
493-
-DLLVM_TARGETS_TO_BUILD="host" \
494-
-DRUNTIMES_BUILD_ALLOW_DARWIN=ON \
495-
-DLLVM_ENABLE_ASSERTIONS=ON
496-
497-
echo "+++ Running the libc++ and libc++abi tests"
498-
${NINJA} -C "${BUILD_DIR}" check-runtimes
499-
500-
echo "--- Installing libc++ and libc++abi to a fake location"
501-
${NINJA} -C "${BUILD_DIR}" install-runtimes
502-
;;
503521
aarch64)
504522
clean
505523
generate-cmake -C "${MONOREPO_ROOT}/libcxx/cmake/caches/AArch64.cmake"

0 commit comments

Comments
 (0)