Skip to content

Commit 002a9a0

Browse files
authored
[ci] Update CI for clang 16 valgrind (#98)
* Update CI for clang 16 valgrind * Renable valgrind for clang16 - Install latest valgrind 3.22 from snap - mark pytest output true for macos * Remove macos pytest true * Add llvm 18 job, make InterOp build debug * Remove set true on llvm 18 valgrind retcode
1 parent ec9fb17 commit 002a9a0

File tree

1 file changed

+33
-8
lines changed

1 file changed

+33
-8
lines changed

.github/workflows/ci.yml

Lines changed: 33 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,12 @@ jobs:
2121
fail-fast: false
2222
matrix:
2323
include:
24+
- name: ubu22-x86-gcc12-clang-repl-18-cppyy
25+
os: ubuntu-22.04
26+
compiler: gcc-12
27+
clang-runtime: '18'
28+
cling: Off
29+
cppyy: On
2430
- name: ubu22-x86-gcc12-clang-repl-17-cppyy
2531
os: ubuntu-22.04
2632
compiler: gcc-12
@@ -121,6 +127,12 @@ jobs:
121127
# cling: On
122128
# cling-version: '1.0'
123129
# cppyy: On
130+
- name: osx13-x86-clang-clang-repl-18-cppyy
131+
os: macos-13
132+
compiler: clang
133+
clang-runtime: '18'
134+
cling: Off
135+
cppyy: On
124136
- name: osx13-x86-clang-clang-repl-17-cppyy
125137
os: macos-13
126138
compiler: clang
@@ -337,7 +349,14 @@ jobs:
337349
run: |
338350
# Install deps
339351
sudo apt-get update
340-
sudo apt-get install git g++ debhelper devscripts gnupg python3 valgrind
352+
sudo apt-get install git g++ debhelper devscripts gnupg python3
353+
sudo apt-get install -y libc6-dbg
354+
sudo snap install valgrind --classic
355+
356+
# Install libraries used by the cppyy test suite
357+
sudo apt install libeigen3-dev
358+
sudo apt install libboost-all-dev
359+
341360
conda install -y -q -c conda-forge \
342361
distro \
343362
pytest
@@ -412,9 +431,12 @@ jobs:
412431
# Now build gtest.a and gtest_main for CppInterOp to run its tests.
413432
cmake --build . --target gtest_main --parallel ${{ env.ncpus }}
414433
else
415-
# Apply patches
416-
git apply -v ../cppyy-backend/patches/llvm/clang${{ matrix.clang-runtime }}-*.patch
417-
echo "Apply clang${{ matrix.clang-runtime }}-*.patch patches:"
434+
# Apply patches
435+
llvm_vers=$(echo "${{ matrix.clang-runtime }}" | tr '[:lower:]' '[:upper:]')
436+
if [[ "${llvm_vers}" != "18" ]]; then
437+
git apply -v ../cppyy-backend/patches/llvm/clang${{ matrix.clang-runtime }}-*.patch
438+
echo "Apply clang${{ matrix.clang-runtime }}-*.patch patches:"
439+
fi
418440
cd build
419441
cmake -DLLVM_ENABLE_PROJECTS=clang \
420442
-DLLVM_TARGETS_TO_BUILD="host;NVPTX" \
@@ -729,10 +751,13 @@ jobs:
729751
python -m pip install pytest-xdist
730752
python -m pip install numba
731753
echo ::endgroup::
754+
732755
echo ::group::Run complete test suite
733756
set -o pipefail
734757
python -m pytest -sv | tee complete_testrun.log 2>&1
735758
set +o pipefail
759+
echo ::endgroup::
760+
736761
echo ::group::Crashing Test Logs
737762
# See if we don't have a crash that went away
738763
# Comment out all xfails but the ones that have a run=False condition.
@@ -757,12 +782,12 @@ jobs:
757782
if [[ "${{ matrix.os }}" == macos-* ]]; then
758783
echo "Skipping Valgrind checks on macOS"
759784
else
760-
if [[ "${{ matrix.clang-runtime }}" == "17" || "${{ matrix.clang-runtime }}" == "18" ]]; then
761-
echo "Valgrind reports true for clang-runtime 17 or 18, due to memory leaks with LLVM"
762-
valgrind --error-exitcode=1 --suppressions=../etc/valgrind-cppyy-cling.supp python -m pytest -m "not xfail" -v || true
785+
if [[ "${{ matrix.clang-runtime }}" == "17" ]]; then
786+
echo "Valgrind reports true for clang-runtime 17, due to memory leaks with LLVM"
787+
valgrind --show-error-list=yes --error-exitcode=1 --suppressions=../etc/valgrind-cppyy-cling.supp python -m pytest -m "not xfail" -v || true
763788
else
764789
echo "Running valgrind on passing tests"
765-
valgrind --error-exitcode=1 --suppressions=../etc/valgrind-cppyy-cling.supp python -m pytest -m "not xfail" -v
790+
valgrind --show-error-list=yes --error-exitcode=1 --suppressions=../etc/valgrind-cppyy-cling.supp python -m pytest -m "not xfail" -v
766791
fi
767792
fi
768793
export RETCODE=+$?

0 commit comments

Comments
 (0)