Skip to content

Add dram_and_fsdax example #735

Add dram_and_fsdax example

Add dram_and_fsdax example #735

Workflow file for this run

# Builds project (with various compilers, CMake options, etc.) and runs tests
name: BasicBuilds
on:
push:
branches-ignore:
- 'dependabot/**'
pull_request:
permissions:
contents: read
env:
# for installation testing - it should match with version set in CMake
UMF_VERSION: 0.10.0
BUILD_DIR : "${{github.workspace}}/build"
INSTL_DIR : "${{github.workspace}}/../install-dir"
jobs:
ubuntu-build:
name: Ubuntu
strategy:
matrix:
os: ['ubuntu-20.04', 'ubuntu-22.04']
build_type: [Debug, Release]
compiler: [{c: gcc, cxx: g++}]
shared_library: ['OFF']
level_zero_provider: ['ON']
cuda_provider: ['ON']
install_tbb: ['ON']
disable_hwloc: ['OFF']
link_hwloc_statically: ['OFF']
include:
# test icx compiler
- os: 'ubuntu-22.04'
build_type: Release
compiler: {c: icx, cxx: icpx}
shared_library: 'ON'
level_zero_provider: 'ON'
cuda_provider: 'ON'
install_tbb: 'ON'
disable_hwloc: 'OFF'
link_hwloc_statically: 'OFF'
# test without installing TBB
- os: 'ubuntu-22.04'
build_type: Release
compiler: {c: gcc, cxx: g++}
shared_library: 'ON'
level_zero_provider: 'ON'
cuda_provider: 'ON'
install_tbb: 'OFF'
disable_hwloc: 'OFF'
link_hwloc_statically: 'OFF'
runs-on: ${{matrix.os}}
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
fetch-depth: 0
- name: Install apt packages
run: |
sudo apt-get update
sudo apt-get install -y clang cmake libnuma-dev libjemalloc-dev
- name: Install TBB apt package
if: matrix.install_tbb == 'ON'
run: |
sudo apt-get install -y libtbb-dev
- name: Install oneAPI basekit
if: matrix.compiler.cxx == 'icpx'
run: |
sudo apt-get install -y gpg-agent wget
wget -O- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB | gpg --dearmor | sudo tee /usr/share/keyrings/oneapi-archive-keyring.gpg > /dev/null
echo "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list
sudo apt-get update
sudo apt-get install -y intel-oneapi-ippcp-devel intel-oneapi-ipp-devel intel-oneapi-common-oneapi-vars intel-oneapi-compiler-dpcpp-cpp
- name: Install g++-7
if: matrix.compiler.cxx == 'g++-7'
run: sudo apt-get install -y ${{matrix.compiler.cxx}}
- name: Install libhwloc
run: .github/scripts/install_hwloc.sh
- name: Set ptrace value for IPC test
run: sudo bash -c "echo 0 > /proc/sys/kernel/yama/ptrace_scope"
- name: Configure build
run: >
${{ matrix.compiler.cxx == 'icpx' && '. /opt/intel/oneapi/setvars.sh &&' || ''}}
cmake
-B ${{env.BUILD_DIR}}
-DCMAKE_INSTALL_PREFIX="${{env.INSTL_DIR}}"
-DCMAKE_BUILD_TYPE=${{matrix.build_type}}
-DUMF_BUILD_SHARED_LIBRARY=${{matrix.shared_library}}
-DCMAKE_C_COMPILER=${{matrix.compiler.c}}
-DCMAKE_CXX_COMPILER=${{matrix.compiler.cxx}}
-DUMF_BUILD_LEVEL_ZERO_PROVIDER=${{matrix.level_zero_provider}}
-DUMF_BUILD_CUDA_PROVIDER=${{matrix.cuda_provider}}
-DUMF_FORMAT_CODE_STYLE=OFF
-DUMF_DEVELOPER_MODE=ON
-DUMF_BUILD_LIBUMF_POOL_JEMALLOC=ON
-DUMF_BUILD_LIBUMF_POOL_DISJOINT=ON
-DUMF_TESTS_FAIL_ON_SKIP=ON
-DUMF_DISABLE_HWLOC=${{matrix.disable_hwloc}}
-DUMF_LINK_HWLOC_STATICALLY=${{matrix.link_hwloc_statically}}
- name: Build UMF
run: |
${{ matrix.compiler.cxx == 'icpx' && '. /opt/intel/oneapi/setvars.sh' || true }}
cmake --build ${{env.BUILD_DIR}} -j $(nproc)
- name: Run tests
working-directory: ${{env.BUILD_DIR}}
run: |
${{ matrix.compiler.cxx == 'icpx' && '. /opt/intel/oneapi/setvars.sh' || true }}
ctest --output-on-failure --test-dir test
- name: Remove the installation directory
run: rm -rf ${{env.INSTL_DIR}}
- name: Test UMF installation and uninstallation
# The '--shared-library' parameter is added to the installation test when the UMF is built as a shared library
run: >
python3 ${{github.workspace}}/test/test_installation.py
--build-dir ${{env.BUILD_DIR}}
--install-dir ${{env.INSTL_DIR}}
--build-type ${{matrix.build_type}}
--disjoint-pool
--jemalloc-pool
${{ matrix.install_tbb == 'ON' && matrix.disable_hwloc != 'ON' && matrix.link_hwloc_statically != 'ON' && '--proxy' || '' }}
--umf-version ${{env.UMF_VERSION}}
${{ matrix.shared_library == 'ON' && '--shared-library' || '' }}