From 2b2f025138e92a4e8df7fcee9ba351e49a2a3397 Mon Sep 17 00:00:00 2001 From: Alexey Oralov Date: Thu, 11 Feb 2021 17:03:32 +0300 Subject: Extend CI tests (#110) * Extend CI tests * Added 8 to -j make parameter * Updated envs path for tests * Deleted Tests_backend_tbb_cxx_11 test from Windows check * Deleted Tests_backend_tbb_cxx_17 test from Windows check * Updated tests description --- jenkinsfiles/RHEL_Check.groovy | 2 +- jenkinsfiles/UB18_Check.groovy | 44 +++++++++++++++++++++++++++++++++----- jenkinsfiles/UB20_Check.groovy | 41 ++++++++++++++++++++++++++++++----- jenkinsfiles/Windows_Check.groovy | 45 ++++++++++++++++++++++++++++++++++++--- 4 files changed, 118 insertions(+), 14 deletions(-) diff --git a/jenkinsfiles/RHEL_Check.groovy b/jenkinsfiles/RHEL_Check.groovy index 253a588a41c7..f8215fb7d002 100644 --- a/jenkinsfiles/RHEL_Check.groovy +++ b/jenkinsfiles/RHEL_Check.groovy @@ -224,7 +224,7 @@ pipeline { sh script: """ export PATH=/usr/bin/:$PATH cmake -DCMAKE_CXX_COMPILER=dpcpp -DCMAKE_CXX_STANDARD=17 -DONEDPL_BACKEND=dpcpp -DONEDPL_DEVICE_TYPE=GPU -DCMAKE_BUILD_TYPE=release . - make VERBOSE=1 build-all -j -k || true + make VERBOSE=1 build-all -j`nproc` -k || true ctest --output-on-failure --timeout ${TEST_TIMEOUT} """, label: "all tests" } diff --git a/jenkinsfiles/UB18_Check.groovy b/jenkinsfiles/UB18_Check.groovy index ad4aec153609..47d8db793c3f 100644 --- a/jenkinsfiles/UB18_Check.groovy +++ b/jenkinsfiles/UB18_Check.groovy @@ -216,17 +216,50 @@ pipeline { } } - stage('Check_tests') { + stage('Tests_dpcpp_cpu_cxx_17') { steps { timeout(time: 2, unit: 'HOURS') { script { try { - dir("./src") { - withEnv(readFile('../envs_tobe_loaded.txt').split('\n') as List) { + dir("./src/build") { + withEnv(readFile('../../envs_tobe_loaded.txt').split('\n') as List) { sh script: """ - cmake -DCMAKE_CXX_COMPILER=dpcpp -DCMAKE_CXX_STANDARD=17 -DONEDPL_BACKEND=dpcpp -DONEDPL_DEVICE_TYPE=CPU -DCMAKE_BUILD_TYPE=release . - make VERBOSE=1 build-all -j -k || true + rm -rf * + cmake -DCMAKE_CXX_COMPILER=dpcpp -DCMAKE_CXX_STANDARD=17 -DONEDPL_BACKEND=dpcpp -DONEDPL_DEVICE_TYPE=CPU -DCMAKE_BUILD_TYPE=release .. + make VERBOSE=1 build-all -j`nproc` -k || true ctest --output-on-failure --timeout ${TEST_TIMEOUT} + + """, label: "All tests" + } + } + } + catch(e) { + build_ok = false + catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') { + sh script: """ + exit -1 + """ + + } + } + } + } + } + } + + stage('Tests_g++_tbb_cxx_17') { + steps { + timeout(time: 2, unit: 'HOURS') { + script { + try { + dir("./src/build") { + withEnv(readFile('../../envs_tobe_loaded.txt').split('\n') as List) { + sh script: """ + rm -rf * + cmake -DCMAKE_CXX_COMPILER=g++ -DCMAKE_CXX_STANDARD=17 -DONEDPL_BACKEND=tbb -DONEDPL_DEVICE_TYPE=HOST -DCMAKE_BUILD_TYPE=release .. + make VERBOSE=1 build-all -j`nproc` -k || true + ctest --output-on-failure --timeout ${TEST_TIMEOUT} + """, label: "All tests" } } @@ -237,6 +270,7 @@ pipeline { sh script: """ exit -1 """ + } } } diff --git a/jenkinsfiles/UB20_Check.groovy b/jenkinsfiles/UB20_Check.groovy index 827902b51e15..806f102af657 100644 --- a/jenkinsfiles/UB20_Check.groovy +++ b/jenkinsfiles/UB20_Check.groovy @@ -206,16 +206,47 @@ pipeline { } } - stage('Check_tests') { + stage('Tests_dpcpp_cpu_cxx_17') { steps { timeout(time: 2, unit: 'HOURS') { script { try { - dir("./src") { - withEnv(readFile('../envs_tobe_loaded.txt').split('\n') as List) { + dir("./src/build") { + withEnv(readFile('../../envs_tobe_loaded.txt').split('\n') as List) { sh script: """ - cmake -DCMAKE_CXX_COMPILER=dpcpp -DCMAKE_CXX_STANDARD=17 -DONEDPL_BACKEND=dpcpp -DONEDPL_DEVICE_TYPE=CPU -DCMAKE_BUILD_TYPE=release . - make VERBOSE=1 build-all -j -k || true + rm -rf * + cmake -DCMAKE_CXX_COMPILER=dpcpp -DCMAKE_CXX_STANDARD=17 -DONEDPL_BACKEND=dpcpp -DONEDPL_DEVICE_TYPE=CPU -DCMAKE_BUILD_TYPE=release .. + make VERBOSE=1 build-all -j`nproc` -k || true + ctest --output-on-failure --timeout ${TEST_TIMEOUT} + """, label: "All tests" + } + } + } + catch(e) { + build_ok = false + echo "Exception is" + e.toString() + catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') { + sh script: """ + exit -1 + """ + } + } + } + } + } + } + + stage('Tests_g++_tbb_cxx_11') { + steps { + timeout(time: 2, unit: 'HOURS') { + script { + try { + dir("./src/build") { + withEnv(readFile('../../envs_tobe_loaded.txt').split('\n') as List) { + sh script: """ + rm -rf * + cmake -DCMAKE_CXX_COMPILER=g++ -DCMAKE_CXX_STANDARD=11 -DONEDPL_BACKEND=tbb -DONEDPL_DEVICE_TYPE=HOST -DCMAKE_BUILD_TYPE=release .. + make VERBOSE=1 build-all -j`nproc` -k || true ctest --output-on-failure --timeout ${TEST_TIMEOUT} """, label: "All tests" } diff --git a/jenkinsfiles/Windows_Check.groovy b/jenkinsfiles/Windows_Check.groovy index c92a4526ccc7..66785fde3b45 100644 --- a/jenkinsfiles/Windows_Check.groovy +++ b/jenkinsfiles/Windows_Check.groovy @@ -285,23 +285,24 @@ pipeline { } } - stage('Check_tests') { + stage('Tests_dpcpp_gpu_cxx_17') { steps { timeout(time: 2, unit: 'HOURS') { script { try { script { withEnv(oneapi_env) { - dir("./src") { + dir("./src/build") { bat script: """ set MAKE_PROGRAM=%DevEnvDir%CommonExtensions\\Microsoft\\CMake\\Ninja\\ninja.exe + rd /s /q . 2>nul cmake -G "Ninja" -DCMAKE_MAKE_PROGRAM="%MAKE_PROGRAM%"^ -DCMAKE_TOOLCHAIN_FILE=cmake\\windows-dpcpp-toolchain.cmake^ -DCMAKE_CXX_STANDARD=17^ -DCMAKE_BUILD_TYPE=release^ -DCMAKE_CXX_COMPILER=dpcpp^ -DONEDPL_BACKEND=dpcpp^ - -DONEDPL_DEVICE_TYPE=GPU . + -DONEDPL_DEVICE_TYPE=GPU .. "%MAKE_PROGRAM%" build-all -v -k 0 ctest --output-on-failure -C release --timeout %TEST_TIMEOUT% """, label: "All tests" @@ -320,6 +321,44 @@ pipeline { } } } + + stage('Tests_cl_tbb_cxx_11') { + steps { + timeout(time: 2, unit: 'HOURS') { + script { + try { + script { + withEnv(oneapi_env) { + dir("./src/build") { + bat script: """ + set MAKE_PROGRAM=%DevEnvDir%CommonExtensions\\Microsoft\\CMake\\Ninja\\ninja.exe + rd /s /q . 2>nul + cmake -G "Ninja" -DCMAKE_MAKE_PROGRAM="%MAKE_PROGRAM%"^ + -DCMAKE_TOOLCHAIN_FILE=cmake\\windows-dpcpp-toolchain.cmake^ + -DCMAKE_CXX_STANDARD=11^ + -DCMAKE_BUILD_TYPE=release^ + -DCMAKE_CXX_COMPILER=cl^ + -DONEDPL_BACKEND=tbb^ + -DONEDPL_DEVICE_TYPE=HOST .. + "%MAKE_PROGRAM%" build-all -v -k 0 + ctest --output-on-failure -C release --timeout %TEST_TIMEOUT% + """, label: "All tests" + } + } + } + } + catch(e) { + build_ok = false + echo "Exception is" + e.toString() + catchError(buildResult: 'SUCCESS', stageResult: 'FAILURE') { + bat 'exit 1' + } + } + } + } + } + } + } } -- cgit v1.2.3-65-gdbad