Skip to content

Commit

Permalink
fix conflicts and improve the region names
Browse files Browse the repository at this point in the history
  • Loading branch information
Yuuichi Asahi committed Jan 21, 2025
2 parents e6beb90 + d991b0c commit df4b0b8
Show file tree
Hide file tree
Showing 27 changed files with 1,091 additions and 822 deletions.
150 changes: 150 additions & 0 deletions .github/workflows/build_nightly.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,150 @@
# SPDX-FileCopyrightText: (C) The kokkos-fft development team, see COPYRIGHT.md file
#
# SPDX-License-Identifier: MIT OR Apache-2.0 WITH LLVM-exception

# Build and test Kokkos FFT using Docker and Singularity images. Pre-generated
# images are pulled from Github registry.

name: Nightly tests

on:
schedule:
- cron: "0 1 * * 1-5" # every weekday at 1am

env:
# Force the use of BuildKit for Docker
DOCKER_BUILDKIT: 1

jobs:
# build project
build:
# only run on original repo
if: github.repository == 'kokkos/kokkos-fft'

runs-on: ubuntu-latest

strategy:
matrix:
backend:
- name: openmp
image: gcc
compiler:
c: gcc
cxx: g++
cmake_flags:
cxx_standard: 17
kokkos: -DKokkos_ENABLE_OPENMP=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra" -DCMAKE_COMPILE_WARNING_AS_ERROR=ON
- name: threads
image: gcc
compiler:
c: gcc
cxx: g++
cmake_flags:
cxx_standard: 20
kokkos: -DKokkos_ENABLE_THREADS=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra" -DCMAKE_COMPILE_WARNING_AS_ERROR=ON
- name: serial
image: gcc
compiler:
c: gcc
cxx: g++
cmake_flags:
cxx_standard: 17
kokkos: -DKokkos_ENABLE_SERIAL=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra" -DCMAKE_COMPILE_WARNING_AS_ERROR=ON
- name: cuda
image: nvcc
compiler:
c: gcc
cxx: g++
cmake_flags:
cxx_standard: 17
kokkos: -DKokkos_ENABLE_CUDA=ON -DKokkos_ARCH_AMPERE80=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra -Werror"
- name: hip
image: rocm
compiler:
c: hipcc
cxx: hipcc
cmake_flags:
cxx_standard: 17
kokkos: -DKokkos_ENABLE_HIP=ON -DKokkos_ARCH_VEGA90A=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra -Werror"
- name: rocm
image: rocm
compiler:
c: hipcc
cxx: hipcc
cmake_flags:
cxx_standard: 20
kokkos: -DKokkos_ENABLE_HIP=ON -DKokkos_ARCH_VEGA90A=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra -Werror" -DKokkosFFT_ENABLE_ROCFFT=ON
- name: sycl
image: intel
compiler:
c: icx
cxx: icpx
cmake_flags:
# building for Intel PVC was unsuccessful without the proper
# device, so for now, we simply generate generic Intel GPU code
cxx_standard: 17
kokkos: -DKokkos_ENABLE_SYCL=ON -DKokkos_ARCH_INTEL_GEN=ON
kokkos_fft: -DCMAKE_CXX_FLAGS="-Wall -Wextra"
steps:
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/[email protected]
with:
tool-cache: true
large-packages: false

- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive

- name: Checkout Kokkos devel branch
uses: actions/checkout@v4
with:
repository: kokkos/kokkos
path: kokkos

- name: Configure Kokkos
run: |
docker run -v ${{ github.workspace }}:/work ghcr.io/kokkos/kokkos-fft/base_${{ matrix.backend.image }}_main:latest \
cmake -B build_kokkos \
-DCMAKE_INSTALL_PREFIX=/work/install \
-DCMAKE_C_COMPILER=${{ matrix.backend.compiler.c }} \
-DCMAKE_CXX_COMPILER=${{ matrix.backend.compiler.cxx }} \
-DCMAKE_CXX_STANDARD=${{ matrix.backend.cmake_flags.cxx_standard }} \
-DCMAKE_BUILD_TYPE=${{ matrix.backend.cmake_build_type }} \
${{ matrix.backend.cmake_flags.kokkos }} \
kokkos
- name: Build Kokkos
run: |
docker run -v ${{ github.workspace }}:/work ghcr.io/kokkos/kokkos-fft/base_${{ matrix.backend.image }}_main:latest \
cmake --build build_kokkos -j $(( $(nproc) * 2 + 1 ))
- name: Install Kokkos
run: |
docker run -v ${{ github.workspace }}:/work ghcr.io/kokkos/kokkos-fft/base_${{ matrix.backend.image }}_main:latest \
cmake --install build_kokkos
- name: Configure
run: |
docker run -v ${{ github.workspace }}:/work ghcr.io/kokkos/kokkos-fft/base_${{ matrix.backend.image }}_main:latest \
cmake -B build \
-DCMAKE_PREFIX_PATH=/work/install \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=${{ matrix.backend.compiler.c }} \
-DCMAKE_CXX_COMPILER=${{ matrix.backend.compiler.cxx }} \
-DCMAKE_CXX_STANDARD=${{ matrix.backend.cmake_flags.cxx_standard }} \
-DKokkosFFT_ENABLE_EXAMPLES=ON \
-DKokkosFFT_ENABLE_TESTS=ON \
${{ matrix.backend.cmake_flags.kokkos_fft }}
- name: Build
run: |
docker run -v ${{ github.workspace }}:/work ghcr.io/kokkos/kokkos-fft/base_${{ matrix.backend.image }}_main:latest \
cmake --build build -j $(( $(nproc) * 2 + 1 ))
5 changes: 5 additions & 0 deletions .github/workflows/build_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,7 @@ jobs:
# test the project
test:
runs-on: ${{ matrix.backend.runner }}
continue-on-error: ${{ matrix.backend.unstable }}

needs:
- check_docker_files
Expand All @@ -317,21 +318,25 @@ jobs:
image: nvcc
runner: [self-hosted, cuda]
use_singularity: true
unstable: true
# run OpenMP tests on Azure server
- name: openmp
image: gcc
runner: ubuntu-latest
use_singularity: false
unstable: false
# run Threads tests on Azure server
- name: threads
image: gcc
runner: ubuntu-latest
use_singularity: false
unstable: false
# run Serial tests on Azure server
- name: serial
image: gcc
runner: ubuntu-latest
use_singularity: false
unstable: false

steps:
- name: Get artifacts
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ SPDX-License-Identifier: MIT OR Apache-2.0 WITH LLVM-exception
# kokkos-fft

[![CI](https://github.com/kokkos/kokkos-fft/actions/workflows/build_test.yaml/badge.svg)](https://github.com/kokkos/kokkos-fft/actions)
[![Nightly builds](https://github.com/kokkos/kokkos-fft/actions/workflows/build_nightly.yaml/badge.svg)](https://github.com/kokkos/kokkos-fft/actions/workflows/build_nightly.yaml)
[![docs](https://readthedocs.org/projects/kokkosfft/badge/?version=latest)](https://kokkosfft.readthedocs.io/en/latest/?badge=latest)

> [!WARNING]
Expand Down
2 changes: 1 addition & 1 deletion common/src/KokkosFFT_utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ bool are_valid_axes(const ViewType& view, const ArrayType<IntType, DIM>& axes) {
"are_valid_axes: the Rank of FFT axes must be between 1 and View rank");

// Convert the input axes to be in the range of [0, rank-1]
// int type is choosen for consistency with the rest of the code
// int type is chosen for consistency with the rest of the code
// the axes are defined with int type
std::array<int, DIM> non_negative_axes;

Expand Down
Loading

0 comments on commit df4b0b8

Please sign in to comment.