Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
342 changes: 171 additions & 171 deletions .github/workflows/ci.cpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,133 +12,133 @@ concurrency:

jobs:

build-cpu:
runs-on: ubuntu-latest
name: ${{ matrix.name }}
strategy:
fail-fast: false
matrix:
include:
- { name: "CPU (clang 16, Debug)", build: "Debug", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-stdlib=libc++" }
- { name: "CPU (clang 16, Debug, c++23)", build: "Debug", tag: llvm16-cuda12.9, cxxstd: "23", cxxflags: "-stdlib=libc++" }
- { name: "CPU (clang 16, Debug, TSAN)", build: "Debug", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=thread" }
- { name: "CPU (clang 16, Release)", build: "Release", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-stdlib=libc++" }
- { name: "CPU (clang 16, Release, ASAN)", build: "Release", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-stdlib=libc++ -fsanitize=address -fsanitize-ignorelist=/home/coder/stdexec/sanitizer-ignorelist.txt" }
- { name: "CPU (clang 22, Debug)", build: "Debug", tag: llvm22-cuda13.2, cxxstd: "23", cxxflags: "-stdlib=libc++" }
- { name: "CPU (clang 22, Release)", build: "Release", tag: llvm22-cuda13.2, cxxstd: "23", cxxflags: "-stdlib=libc++" }
- { name: "CPU (gcc 12, Debug)", build: "Debug", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "", }
- { name: "CPU (gcc 12, Release)", build: "Release", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "", }
# With the following config, 2 tests mysteriously time out, but only in CI and not locally.
# - { name: "CPU (gcc 12, Release, ASAN)", build: "Release", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=address" }
- { name: "CPU (gcc 12, Release, TSAN)", build: "Release", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=thread" }
- { name: "CPU (gcc 13, Debug)", build: "Debug", tag: gcc13-cuda12.9, cxxstd: "20", cxxflags: "", }
- { name: "CPU (gcc 14, Debug)", build: "Debug", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "", }
- { name: "CPU (gcc 14, Debug, ASAN)", build: "Debug", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=address" }
- { name: "CPU (gcc 14, Debug, TSAN)", build: "Debug", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=thread" }
- { name: "CPU (gcc 14, Release, ASAN)", build: "Release", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=address" }
- { name: "CPU (gcc 14, Release, LEAK)", build: "Release", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=leak", }
- { name: "CPU (gcc 14, Release, c++23)", build: "Release", tag: gcc14-cuda12.9, cxxstd: "23", cxxflags: "", }
container:
options: -u root
image: rapidsai/devcontainers:26.06-cpp-${{ matrix.tag }}
permissions:
id-token: write # This is required for configure-aws-credentials
contents: read # This is required for actions/checkout
defaults:
run:
shell: su coder {0}
working-directory: /home/coder
steps:
- name: Checkout stdexec
uses: actions/checkout@v4
with:
path: stdexec
persist-credentials: false
- name: Setup environment
run: |
echo "ARTIFACT_PREFIX=${{runner.os}}-${{matrix.tag}}-amd64" >> "${GITHUB_ENV}"
echo "ARTIFACT_SUFFIX=${{github.run_id}}-${{github.run_attempt}}-$RANDOM" >> "${GITHUB_ENV}"
- if: github.repository_owner == 'NVIDIA'
name: Get AWS credentials for sccache bucket
uses: aws-actions/configure-aws-credentials@v4
with:
aws-region: us-east-2
role-duration-seconds: 28800 # 8 hours
role-to-assume: arn:aws:iam::279114543810:role/gha-oidc-NVIDIA
- name: Build and test CPU schedulers
env:
ASAN_OPTIONS: alloc_dealloc_mismatch=0
NVCC_APPEND_FLAGS: "-t=100"
SCCACHE_BUCKET: "rapids-sccache-devs"
SCCACHE_DIST_REQUEST_TIMEOUT: "7140"
SCCACHE_DIST_URL: "https://amd64.linux.sccache.rapids.nvidia.com"
SCCACHE_IDLE_TIMEOUT: "0"
SCCACHE_REGION: "us-east-2"
SCCACHE_S3_KEY_PREFIX: "nvidia-stdexec-dev"
SCCACHE_S3_PREPROCESSOR_CACHE_KEY_PREFIX: "nvidia-stdexec-dev/preprocessor"
SCCACHE_S3_USE_PREPROCESSOR_CACHE_MODE: "true"
SCCACHE_SERVER_LOG: "sccache=debug"
SCCACHE_SERVER_PORT: "4225"
run: |
set -e;
source /etc/profile
set -x;

devcontainer-utils-install-sccache --version rapids;

devcontainer-utils-init-sccache-dist \
--enable-sccache-dist - <<< " \
--auth-type 'token' \
--auth-token '$( \
curl -fsSL -H "Authorization: Bearer $( \
curl -fsSL -H "Authorization: bearer $ACTIONS_ID_TOKEN_REQUEST_TOKEN" \
"${ACTIONS_ID_TOKEN_REQUEST_URL}&audience=token.rapids.nvidia.com" \
| jq -r '.value' \
)" https://token.rapids.nvidia.com/gh/token/exchange \
| jq -r '.token')' \
";

# Copy source folder into ~/stdexec
cp -r "${GITHUB_WORKSPACE}"/stdexec ~/;
chown -R coder:coder ~/stdexec;
cd ~/stdexec;

# Configure
cmake -S . -B build -GNinja \
-DCMAKE_BUILD_TYPE=${{ matrix.build }} \
-DCMAKE_CXX_FLAGS="${{ matrix.cxxflags }}" \
-DSTDEXEC_ENABLE_TBB:BOOL=${{ !contains(matrix.cxxflags, '-fsanitize') }} \
-DSTDEXEC_ENABLE_ASIO:BOOL=TRUE \
-DSTDEXEC_ASIO_IMPLEMENTATION:STRING=boost \
-DCMAKE_CXX_STANDARD:STRING=${{ matrix.cxxstd }} \
-DCMAKE_CXX_EXTENSIONS:BOOL=OFF \
-DSTDEXEC_BUILD_TESTS:BOOL=ON \
;

# Compile
cmake --build build -v -j 512;

# Print sccache stats
sccache -s;

# Tests
SCCACHE_NO_CACHE=1 SCCACHE_NO_DIST_COMPILE=1 \
ctest --test-dir build --verbose --output-on-failure --timeout 60;
- if: ${{ !cancelled() }}
name: Upload sccache logs
uses: actions/upload-artifact@v4
with:
name: sccache-client-logs-${{env.ARTIFACT_PREFIX}}-${{env.ARTIFACT_SUFFIX}}
path: /tmp/sccache*.log
compression-level: 9

ci-cpu:
runs-on: ubuntu-latest
name: CI (CPU)
needs:
- build-cpu
steps:
- run: echo "CI (CPU) success"
# build-cpu:
# runs-on: ubuntu-latest
# name: ${{ matrix.name }}
# strategy:
# fail-fast: false
# matrix:
# include:
# - { name: "CPU (clang 16, Debug)", build: "Debug", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-stdlib=libc++" }
# - { name: "CPU (clang 16, Debug, c++23)", build: "Debug", tag: llvm16-cuda12.9, cxxstd: "23", cxxflags: "-stdlib=libc++" }
# - { name: "CPU (clang 16, Debug, TSAN)", build: "Debug", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=thread" }
# - { name: "CPU (clang 16, Release)", build: "Release", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-stdlib=libc++" }
# - { name: "CPU (clang 16, Release, ASAN)", build: "Release", tag: llvm16-cuda12.9, cxxstd: "20", cxxflags: "-stdlib=libc++ -fsanitize=address -fsanitize-ignorelist=/home/coder/stdexec/sanitizer-ignorelist.txt" }
# - { name: "CPU (clang 22, Debug)", build: "Debug", tag: llvm22-cuda13.2, cxxstd: "23", cxxflags: "-stdlib=libc++" }
# - { name: "CPU (clang 22, Release)", build: "Release", tag: llvm22-cuda13.2, cxxstd: "23", cxxflags: "-stdlib=libc++" }
# - { name: "CPU (gcc 12, Debug)", build: "Debug", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "", }
# - { name: "CPU (gcc 12, Release)", build: "Release", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "", }
# # With the following config, 2 tests mysteriously time out, but only in CI and not locally.
# # - { name: "CPU (gcc 12, Release, ASAN)", build: "Release", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=address" }
# - { name: "CPU (gcc 12, Release, TSAN)", build: "Release", tag: gcc12-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=thread" }
# - { name: "CPU (gcc 13, Debug)", build: "Debug", tag: gcc13-cuda12.9, cxxstd: "20", cxxflags: "", }
# - { name: "CPU (gcc 14, Debug)", build: "Debug", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "", }
# - { name: "CPU (gcc 14, Debug, ASAN)", build: "Debug", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=address" }
# - { name: "CPU (gcc 14, Debug, TSAN)", build: "Debug", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=thread" }
# - { name: "CPU (gcc 14, Release, ASAN)", build: "Release", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=address" }
# - { name: "CPU (gcc 14, Release, LEAK)", build: "Release", tag: gcc14-cuda12.9, cxxstd: "20", cxxflags: "-fsanitize=leak", }
# - { name: "CPU (gcc 14, Release, c++23)", build: "Release", tag: gcc14-cuda12.9, cxxstd: "23", cxxflags: "", }
# container:
# options: -u root
# image: rapidsai/devcontainers:26.06-cpp-${{ matrix.tag }}
# permissions:
# id-token: write # This is required for configure-aws-credentials
# contents: read # This is required for actions/checkout
# defaults:
# run:
# shell: su coder {0}
# working-directory: /home/coder
# steps:
# - name: Checkout stdexec
# uses: actions/checkout@v4
# with:
# path: stdexec
# persist-credentials: false
# - name: Setup environment
# run: |
# echo "ARTIFACT_PREFIX=${{runner.os}}-${{matrix.tag}}-amd64" >> "${GITHUB_ENV}"
# echo "ARTIFACT_SUFFIX=${{github.run_id}}-${{github.run_attempt}}-$RANDOM" >> "${GITHUB_ENV}"
# - if: github.repository_owner == 'NVIDIA'
# name: Get AWS credentials for sccache bucket
# uses: aws-actions/configure-aws-credentials@v4
# with:
# aws-region: us-east-2
# role-duration-seconds: 28800 # 8 hours
# role-to-assume: arn:aws:iam::279114543810:role/gha-oidc-NVIDIA
# - name: Build and test CPU schedulers
# env:
# ASAN_OPTIONS: alloc_dealloc_mismatch=0
# NVCC_APPEND_FLAGS: "-t=100"
# SCCACHE_BUCKET: "rapids-sccache-devs"
# SCCACHE_DIST_REQUEST_TIMEOUT: "7140"
# SCCACHE_DIST_URL: "https://amd64.linux.sccache.rapids.nvidia.com"
# SCCACHE_IDLE_TIMEOUT: "0"
# SCCACHE_REGION: "us-east-2"
# SCCACHE_S3_KEY_PREFIX: "nvidia-stdexec-dev"
# SCCACHE_S3_PREPROCESSOR_CACHE_KEY_PREFIX: "nvidia-stdexec-dev/preprocessor"
# SCCACHE_S3_USE_PREPROCESSOR_CACHE_MODE: "true"
# SCCACHE_SERVER_LOG: "sccache=debug"
# SCCACHE_SERVER_PORT: "4225"
# run: |
# set -e;
# source /etc/profile
# set -x;

# devcontainer-utils-install-sccache --version rapids;

# devcontainer-utils-init-sccache-dist \
# --enable-sccache-dist - <<< " \
# --auth-type 'token' \
# --auth-token '$( \
# curl -fsSL -H "Authorization: Bearer $( \
# curl -fsSL -H "Authorization: bearer $ACTIONS_ID_TOKEN_REQUEST_TOKEN" \
# "${ACTIONS_ID_TOKEN_REQUEST_URL}&audience=token.rapids.nvidia.com" \
# | jq -r '.value' \
# )" https://token.rapids.nvidia.com/gh/token/exchange \
# | jq -r '.token')' \
# ";

# # Copy source folder into ~/stdexec
# cp -r "${GITHUB_WORKSPACE}"/stdexec ~/;
# chown -R coder:coder ~/stdexec;
# cd ~/stdexec;

# # Configure
# cmake -S . -B build -GNinja \
# -DCMAKE_BUILD_TYPE=${{ matrix.build }} \
# -DCMAKE_CXX_FLAGS="${{ matrix.cxxflags }}" \
# -DSTDEXEC_ENABLE_TBB:BOOL=${{ !contains(matrix.cxxflags, '-fsanitize') }} \
# -DSTDEXEC_ENABLE_ASIO:BOOL=TRUE \
# -DSTDEXEC_ASIO_IMPLEMENTATION:STRING=boost \
# -DCMAKE_CXX_STANDARD:STRING=${{ matrix.cxxstd }} \
# -DCMAKE_CXX_EXTENSIONS:BOOL=OFF \
# -DSTDEXEC_BUILD_TESTS:BOOL=ON \
# ;

# # Compile
# cmake --build build -v -j 512;

# # Print sccache stats
# sccache -s;

# # Tests
# SCCACHE_NO_CACHE=1 SCCACHE_NO_DIST_COMPILE=1 \
# ctest --test-dir build --verbose --output-on-failure --timeout 60;
# - if: ${{ !cancelled() }}
# name: Upload sccache logs
# uses: actions/upload-artifact@v4
# with:
# name: sccache-client-logs-${{env.ARTIFACT_PREFIX}}-${{env.ARTIFACT_SUFFIX}}
# path: /tmp/sccache*.log
# compression-level: 9

# ci-cpu:
# runs-on: ubuntu-latest
# name: CI (CPU)
# needs:
# - build-cpu
# steps:
# - run: echo "CI (CPU) success"

build-cpu-windows:
runs-on: windows-2022
Expand Down Expand Up @@ -174,47 +174,47 @@ jobs:
steps:
- run: echo "CI (CPU) (Windows) success"

build-cpu-macos:
runs-on: macos-26-large
name: macos-${{ matrix.name }}
strategy:
fail-fast: false
matrix:
include:
- { compiler: "clang++", build: "Debug", name: "CPU (MacOS) (clang, Debug)" }
- { compiler: "clang++", build: "Release", name: "CPU (MacOS) (clang, Release)" }
steps:
- name: Checkout stdexec (MacOS)
uses: actions/checkout@v4
with:
persist-credentials: false

- name: Install dependencies
run: |
brew update
brew install ninja
shell: bash

- name: Build and test CPU schedulers (MacOS)
shell: bash
run: |
mkdir build
cmake -S. -Bbuild -GNinja \
-DCMAKE_BUILD_TYPE=${{ matrix.build }} \
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }} \
-DSTDEXEC_ENABLE_ASIO:BOOL=TRUE \
-DSTDEXEC_ASIO_IMPLEMENTATION:STRING=boost \
-DCMAKE_CXX_STANDARD:STRING=20 \
-DSTDEXEC_BUILD_TESTS:BOOL=ON

cmake --build build/ -v
cd build
ctest --output-on-failure

ci-cpu-macos:
runs-on: macos-latest-large
name: CI (CPU) (MacOS)
needs:
- build-cpu-macos
steps:
- run: echo "CI (CPU) (MacOS) success"
# build-cpu-macos:
# runs-on: macos-26-large
# name: macos-${{ matrix.name }}
# strategy:
# fail-fast: false
# matrix:
# include:
# - { compiler: "clang++", build: "Debug", name: "CPU (MacOS) (clang, Debug)" }
# - { compiler: "clang++", build: "Release", name: "CPU (MacOS) (clang, Release)" }
# steps:
# - name: Checkout stdexec (MacOS)
# uses: actions/checkout@v4
# with:
# persist-credentials: false

# - name: Install dependencies
# run: |
# brew update
# brew install ninja
# shell: bash

# - name: Build and test CPU schedulers (MacOS)
# shell: bash
# run: |
# mkdir build
# cmake -S. -Bbuild -GNinja \
# -DCMAKE_BUILD_TYPE=${{ matrix.build }} \
# -DCMAKE_CXX_COMPILER=${{ matrix.compiler }} \
# -DSTDEXEC_ENABLE_ASIO:BOOL=TRUE \
# -DSTDEXEC_ASIO_IMPLEMENTATION:STRING=boost \
# -DCMAKE_CXX_STANDARD:STRING=20 \
# -DSTDEXEC_BUILD_TESTS:BOOL=ON

# cmake --build build/ -v
# cd build
# ctest --output-on-failure

# ci-cpu-macos:
# runs-on: macos-latest-large
# name: CI (CPU) (MacOS)
# needs:
# - build-cpu-macos
# steps:
# - run: echo "CI (CPU) (MacOS) success"
6 changes: 6 additions & 0 deletions .github/workflows/test-windows.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,10 @@ Invoke-NativeCommand cmake -B $BuildDirectory -G Ninja `
"-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON" `
"-DSTDEXEC_BUILD_TESTS:BOOL=TRUE" .
Invoke-NativeCommand cmake --build $BuildDirectory

# Enable AppVerifier for the test executables
Invoke-NativeCommand appverif /verify test.stdexec.exe
Invoke-NativeCommand appverif /verify test.exec.exe

Invoke-NativeCommand ctest --test-dir $BuildDirectory --output-on-failure --verbose --timeout 60

Loading