Move all C++ impl. to ./cpp

This commit is contained in:
Tom Lin 2021-05-23 07:21:21 +01:00
parent 45ebd09ef2
commit 717cc40c2c
76 changed files with 60 additions and 52 deletions

View File

@ -13,86 +13,86 @@ jobs:
uses: actions/cache@v2
with:
path: compilers
key: ${{ runner.os }}-${{ hashFiles('ci-prepare-bionic.sh') }}
key: ${{ runner.os }}-${{ hashFiles('./cpp/ci-prepare-bionic.sh') }}
- name: Prepare compilers
if: steps.prepare-compilers.outputs.cache-hit != 'true'
run: source ./ci-prepare-bionic.sh ./compilers SETUP true || true
run: source ./cpp/ci-prepare-bionic.sh ./compilers SETUP true || true
- name: Setup test environment
run: source ./ci-prepare-bionic.sh ./compilers VARS false || true
run: source ./cpp/ci-prepare-bionic.sh ./compilers VARS false || true
- name: Test compile gcc @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build gcc all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build gcc all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile clang @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build clang all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build clang all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile nvhpc @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build nvhpc all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build nvhpc all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile aocc @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build aocc all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build aocc all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile aomp @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build aomp all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build aomp all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile hip @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build hip all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build hip all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile dpcpp @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build dpcpp all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build dpcpp all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile hipsycl @ CMake 3.13
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build hipsycl all ${{ env.CMAKE_3_13_BIN }}
run: ./cpp/ci-test-compile.sh ./build hipsycl all ${{ env.CMAKE_3_13_BIN }}
- name: Test compile gcc @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build gcc all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build gcc all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile clang @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build clang all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build clang all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile nvhpc @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build nvhpc all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build nvhpc all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile aocc @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build aocc all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build aocc all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile aomp @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build aomp all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build aomp all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile hip @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build hip all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build hip all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile dpcpp @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build dpcpp all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build dpcpp all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile hipsycl @ CMake 3.15
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build hipsycl all ${{ env.CMAKE_3_15_BIN }}
run: ./cpp/ci-test-compile.sh ./build hipsycl all ${{ env.CMAKE_3_15_BIN }}
- name: Test compile gcc @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build gcc all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build gcc all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile clang @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build clang all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build clang all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile nvhpc @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build nvhpc all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build nvhpc all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile aocc @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build aocc all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build aocc all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile aomp @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build aomp all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build aomp all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile hip @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build hip all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build hip all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile dpcpp @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build dpcpp all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build dpcpp all ${{ env.CMAKE_3_18_BIN }}
- name: Test compile hipsycl @ CMake 3.18
if: ${{ ! cancelled() }}
run: ./ci-test-compile.sh ./build hipsycl all ${{ env.CMAKE_3_18_BIN }}
run: ./cpp/ci-test-compile.sh ./build hipsycl all ${{ env.CMAKE_3_18_BIN }}

24
.gitignore vendored
View File

@ -1,30 +1,8 @@
cuda-stream
ocl-stream
omp-stream
acc-stream
raja-stream
kokkos-stream
std-stream
sycl-stream
hip-stream
*.o
*.bc
*.sycl
*.tar
*.gz
*.a
KokkosCore_config.*
.DS_Store
Makefile
build/
cmake-build-*/
CMakeFiles/
.idea/
.vscode/
.directory
.directory

View File

@ -63,7 +63,7 @@ The project supports building with CMake >= 3.13.0, it can be installed without
As with any CMake project, first configure the project:
```shell
> cd babelstream
> cd babelstream/cpp
> cmake -Bbuild -H. -DMODEL=<model> <model specific flags prefixed with -D...> # configure the build, build type defaults to Release
> cmake --build build # compile it
> ./build/babelstream # executable available at ./build/
@ -75,7 +75,7 @@ There are assigned those to `RELEASE_FLAGS`, and you can override them if requir
To find out what flag each model supports or requires, simply configure while only specifying the model.
For example:
```shell
> cd babelstream
> cd babelstream/cpp
> cmake -Bbuild -H. -DMODEL=OCL
...
- Common Release flags are `-O3`, set RELEASE_FLAGS to override

30
cpp/.gitignore vendored Normal file
View File

@ -0,0 +1,30 @@
cuda-stream
ocl-stream
omp-stream
acc-stream
raja-stream
kokkos-stream
std-stream
sycl-stream
hip-stream
*.o
*.bc
*.sycl
*.tar
*.gz
*.a
KokkosCore_config.*
.DS_Store
Makefile
build/
cmake-build-*/
CMakeFiles/
.idea/
.vscode/
.directory