mirror of
https://gitlab.kitware.com/vtk/vtk-m
synced 2024-10-05 01:49:02 +00:00
CI: add ubuntu2004 with tbb 2020 build
This commit is contained in:
parent
7aae612d95
commit
46b0268825
@ -95,6 +95,11 @@
|
||||
extends:
|
||||
- .docker_image
|
||||
|
||||
.ubuntu2004: &ubuntu2004
|
||||
image: "kitware/vtkm:ci-ubuntu2004-20210920"
|
||||
extends:
|
||||
- .docker_image
|
||||
|
||||
.ubuntu2004_kokkos: &ubuntu2004_kokkos
|
||||
image: "kitware/vtkm:ci-ubuntu2004_kokkos-20210916"
|
||||
extends:
|
||||
|
23
.gitlab/ci/docker/ubuntu2004/base/Dockerfile
Normal file
23
.gitlab/ci/docker/ubuntu2004/base/Dockerfile
Normal file
@ -0,0 +1,23 @@
|
||||
FROM ubuntu:20.04
|
||||
LABEL maintainer "Vicente Adolfo Bolea Sanchez<vicente.bolea@kitware.com>"
|
||||
|
||||
ENV TZ=America/New_York
|
||||
|
||||
# Base dependencies for building VTK-m projects
|
||||
RUN apt-get update && DEBIAN_FRONTEND="noninteractive" apt-get install -y --no-install-recommends \
|
||||
cmake \
|
||||
curl \
|
||||
g++ \
|
||||
git \
|
||||
git-lfs \
|
||||
libmpich-dev \
|
||||
libomp-dev \
|
||||
libtbb-dev \
|
||||
libhdf5-dev \
|
||||
mpich \
|
||||
ninja-build \
|
||||
software-properties-common
|
||||
|
||||
# Need to run git-lfs install manually on ubuntu based images when using the
|
||||
# system packaged version
|
||||
RUN git-lfs install
|
@ -1,3 +1,36 @@
|
||||
build:ubuntu2004_gcc9:
|
||||
tags:
|
||||
- build
|
||||
- vtkm
|
||||
- docker
|
||||
- linux
|
||||
extends:
|
||||
- .ubuntu2004
|
||||
- .cmake_build_linux
|
||||
- .only-default
|
||||
variables:
|
||||
CMAKE_BUILD_TYPE: Debug
|
||||
VTKM_SETTINGS: "benchmarks+tbb+openmp+mpi+shared+hdf5"
|
||||
|
||||
test:ubuntu2004_gcc9:
|
||||
tags:
|
||||
- test
|
||||
- vtkm
|
||||
- docker
|
||||
- linux
|
||||
extends:
|
||||
- .ubuntu2004
|
||||
- .cmake_test_linux
|
||||
- .only-default
|
||||
variables:
|
||||
#Restrict OpenMP number of threads since multiple test stages
|
||||
#execute on the same hardware concurrently
|
||||
OMP_NUM_THREADS: 4
|
||||
dependencies:
|
||||
- build:ubuntu2004_gcc9
|
||||
needs:
|
||||
- build:ubuntu2004_gcc9
|
||||
|
||||
build:ubuntu2004_kokkos:
|
||||
tags:
|
||||
- build
|
||||
|
@ -46,11 +46,11 @@ if(VTKm_ENABLE_TBB AND NOT TARGET vtkm::tbb)
|
||||
add_library(vtkmTBB INTERFACE)
|
||||
add_library(vtkm::tbb ALIAS vtkmTBB)
|
||||
target_link_libraries(vtkmTBB INTERFACE TBB::tbb)
|
||||
target_compile_definitions(vtkmTBB INTERFACE "TBB_VERSION_MAJOR=${TBB_VERSION_MAJOR}")
|
||||
set_target_properties(vtkmTBB PROPERTIES EXPORT_NAME vtkm::tbb)
|
||||
install(TARGETS vtkmTBB EXPORT ${VTKm_EXPORT_NAME})
|
||||
endif()
|
||||
|
||||
|
||||
if(VTKm_ENABLE_OPENMP AND NOT TARGET vtkm::openmp)
|
||||
find_package(OpenMP 4.0 REQUIRED COMPONENTS CXX QUIET)
|
||||
|
||||
|
@ -53,9 +53,6 @@
|
||||
#include <sstream>
|
||||
#include <type_traits>
|
||||
|
||||
#ifdef VTKM_ENABLE_TBB
|
||||
#include <tbb/tbb.h>
|
||||
#endif
|
||||
#ifdef VTKM_ENABLE_OPENMP
|
||||
#include <omp.h>
|
||||
#endif
|
||||
|
@ -53,7 +53,13 @@
|
||||
// correct settings so that we don't clobber any existing function
|
||||
#include <vtkm/internal/Windows.h>
|
||||
|
||||
#if TBB_VERSION_MAJOR >= 2020
|
||||
#include <tbb/task.h>
|
||||
#include <tbb/task_group.h>
|
||||
#else
|
||||
#include <tbb/tbb.h>
|
||||
#endif
|
||||
|
||||
#include <thread>
|
||||
|
||||
#if defined(VTKM_MSVC)
|
||||
|
@ -14,7 +14,13 @@
|
||||
#include <vtkm/cont/tbb/internal/DeviceAdapterTagTBB.h>
|
||||
|
||||
VTKM_THIRDPARTY_PRE_INCLUDE
|
||||
#if TBB_VERSION_MAJOR >= 2020
|
||||
#define TBB_PREVIEW_GLOBAL_CONTROL
|
||||
#include <tbb/global_control.h>
|
||||
#include <tbb/task_arena.h>
|
||||
#else
|
||||
#include <tbb/tbb.h>
|
||||
#endif
|
||||
VTKM_THIRDPARTY_POST_INCLUDE
|
||||
|
||||
#include <memory>
|
||||
|
Loading…
Reference in New Issue
Block a user