diff --git a/.jenkins/nightly.groovy b/.jenkins/nightly.groovy index 96979d7b2a..6d848d0b87 100644 --- a/.jenkins/nightly.groovy +++ b/.jenkins/nightly.groovy @@ -88,6 +88,45 @@ pipeline { } } } + stage('MemorySanitizer') { + agent { + docker { + image 'ubuntu:22.04' + label 'docker' + } + } + environment { + CTEST_OPTIONS = '--timeout 180 --no-compress-output -T Test' + CMAKE_OPTIONS = '-D CMAKE_BUILD_TYPE=Release -D CMAKE_CXX_STANDARD=17 -D CMAKE_CXX_EXTENSIONS=OFF -D CMAKE_CXX_COMPILER=clang++ -D CMAKE_CXX_FLAGS="-fsanitize=memory"' + } + steps { + sh 'apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y git cmake libboost-program-options-dev libboost-test-dev libbenchmark-dev clang' + sh 'rm -rf source* build* install*' + sh 'git clone https://github.com/kokkos/kokkos.git --branch develop --depth 1 source-kokkos' + dir('source-kokkos') { + sh 'git rev-parse --short HEAD' + } + sh 'cmake -S source-kokkos -B build-kokkos -D CMAKE_INSTALL_PREFIX=$PWD/install-kokkos $CMAKE_OPTIONS' + sh 'cmake --build build-kokkos --parallel 8' + sh 'cmake --install build-kokkos' + sh 'cmake -B build-arborx -D CMAKE_INSTALL_PREFIX=$PWD/install-arborx -D Kokkos_ROOT=$PWD/install-kokkos $CMAKE_OPTIONS -D ARBORX_ENABLE_BENCHMARKS=ON -' + sh 'cmake --build build-arborx --parallel 8' + dir('build-arborx') { + sh 'ctest $CTEST_OPTIONS' + } + sh 'cmake --install build-arborx' + sh 'cmake -S examples -B build-examples -D ArborX_ROOT=$PWD/install-arborx -D Kokkos_ROOT=$PWD/install-kokkos $CMAKE_OPTIONS' + sh 'cmake --build build-examples --parallel 8' + dir('build-examples') { + sh 'ctest $CTEST_OPTIONS' + } + } + post { + always { + xunit reduceLog: false, tools:[CTest(deleteOutputFiles: true, failIfNotNew: true, pattern: 'build-*/Testing/**/Test.xml', skipNoTestFiles: false, stopProcessingIfError: true)] + } + } + } } } }