forked from PHAREHUB/PHARE
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
890bb7d
commit 2597f70
Showing
219 changed files
with
11,948 additions
and
2,936 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
.mkn* | ||
bin | ||
build | ||
subprojects | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
#! /usr/bin/env bash | ||
|
||
set -ex | ||
|
||
CWD="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
mkdir -p $CWD/build | ||
[ ! -d "$CWD/build" ] && echo "mkn expects cmake configured build directory" && exit 1 | ||
|
||
MKN_X_FILE=${MKN_X_FILE:-settings} | ||
MKN_MPI_X_FILE=${MKN_MPI_X_FILE:-res/mkn/mpi} | ||
MKN_GPU_X_FILE=${MKN_GPU_X_FILE:-res/mkn/clang_cuda} | ||
export MKN_LIB_LINK_LIB=1 | ||
|
||
exit 0 | ||
|
||
# verify compiler setup | ||
# mkn clean build -x ${MKN_GPU_X_FILE} -ga -DKUL_GPU_CUDA dbg -p mkn.gpu_depositor run test | ||
|
||
[ ! -d ./subprojects/thrust ] && \ | ||
git clone https://github.com/NVIDIA/thrust \ | ||
-b main subprojects/thrust --depth 10 --shallow-submodules --recursive | ||
[ ! -d ./subprojects/cuda-samples ] && \ | ||
git clone https://github.com/NVIDIA/cuda-samples \ | ||
-b main subprojects/cuda-samples --depth 10 --shallow-submodules --recursive | ||
|
||
|
||
# gtest doens't like mpi compilers | ||
#mkn clean build -x ${MKN_X_FILE} -p test_diagnostics -tKOd google.test,+ | ||
|
||
#mkn clean build -x ${MKN_MPI_X_FILE} -dtKOp py | ||
|
||
# mkn clean build -x ${MKN_MPI_X_FILE} -p test_diagnostics -KO 9 test run | ||
# mkn clean build -x ${MKN_GPU_X_FILE} -Oa -DKUL_GPU_CUDA run | ||
|
||
#mkn clean build -x ${MKN_GPU_X_FILE} -Op cpp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#! /usr/bin/env bash | ||
|
||
set -ex | ||
|
||
CWD="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
MKN_X_FILE=${MKN_X_FILE:-settings} | ||
MKN_MPI_X_FILE=${MKN_MPI_X_FILE:-res/mkn/mpi} | ||
MKN_GPU_X_FILE=${MKN_GPU_X_FILE:-res/mkn/hip} | ||
|
||
mkdir -p $CWD/build | ||
[ ! -d "$CWD/build" ] && echo "mkn expects cmake configured build directory" && exit 1 | ||
|
||
export MKN_LIB_LINK_LIB=1 | ||
|
||
# verify compiler setup | ||
# mkn clean build -x ${MKN_GPU_X_FILE} -ga -DKUL_GPU_ROCM dbg -p mkn.gpu_depositor run test | ||
|
||
# git clone https://github.com/NVIDIA/thrust -b 1.13.0 subprojects/thrust --depth 10 --shallow-submodules --recursive | ||
|
||
# gtest doens't like mpi compilers | ||
mkn clean build -x ${MKN_X_FILE} -p test_diagnostics -tKOd google.test,+ | ||
|
||
mkn clean build -x ${MKN_MPI_X_FILE} -dtKOp py | ||
|
||
mkn clean build -x ${MKN_MPI_X_FILE} -p test_diagnostics -KO 9 test run | ||
|
||
mkn clean build -x ${MKN_GPU_X_FILE} -Oa -DKUL_GPU_ROCM run |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,214 @@ | ||
#! clean build -x mpi -dtKOp py | ||
|
||
name: phare | ||
|
||
property: | ||
MPI_INC: /usr/include #/hdf5/mpich #/usr/include/hdf5/openmpi #/usr/local/netcdf/include | ||
MPI_LIB: hdf5 | ||
MPI_PTH: /usr/local/lib #/opt/conda/envs/vscode/lib | ||
mkn.gpu: -DPHARE_HAVE_MKN_GPU=1 -DMKN_GPU_CUDA=1 -DPHARE_WITH_KUL=1 | ||
gpu.args: -DPHARE_HAVE_RAJA=1 -DPHARE_WITH_GPU=1 ${mkn.gpu} -DHAVE_RAJA=1 -DHAVE_CUDA=1 | ||
|
||
profile: | ||
- name: umpira_raja_base | ||
arg: -DPHARE_HAVE_RAJA=1 -DPHARE_HAVE_UMPIRE=1 | ||
|
||
- name: base | ||
arg: -Wno-macro-redefined -Wno-unknown-cuda-version -DPHARE_HAS_HIGHFIVE=0 | ||
|
||
- name: gpu_base | ||
parent: base | ||
dep: mkn.gpu llnl.raja[lib] | ||
arg: ${gpu.args} | ||
|
||
- name: core | ||
parent: base | ||
inc: src subprojects | ||
src: src/core | ||
# dep: mkn.kul | ||
out: phare_core | ||
|
||
|
||
- name: test_base | ||
inc: . | ||
dep: google.test | ||
|
||
- name: test_core | ||
parent: test_base | ||
self: core | ||
# test: tests/core/(\w)/(test_.*).cpp | ||
|
||
- name: amr | ||
parent: base | ||
self: core | ||
dep: llnl.samrai(https://github.com/mkn-nix/llnl.samrai) #llnl.raja[lib] mkn.gpu #llnl.umpire[lib] | ||
lib: hdf5_openmpi | ||
src: src/amr | ||
out: phare_amr | ||
|
||
- name: test_amr | ||
parent: test_base | ||
self: amr | ||
|
||
- name: diagnostic | ||
self: amr | ||
dep: hpc.highfive(https://github.com/mkn-nix/hpc.highfive) | ||
inc: build/subprojects/highfive/include | ||
${MPI_INC} | ||
lib: ${MPI_LIB} | ||
path: ${MPI_PTH} | ||
|
||
- name: simulator | ||
parent: base | ||
self: diagnostic | ||
out: phare_simulator | ||
|
||
- name: exe | ||
parent: gpu_base | ||
self: simulator init | ||
dep: lang.pybind11 | ||
main: src/phare/phare.cpp | ||
mod: lang.python3 | ||
env: PYTHONPATH=${MKN_ROOT}:${MKN_ROOT}/tests/diagnostic:${MKN_ROOT}/build:${MKN_ROOT}/pyphare | ||
|
||
- name: init | ||
src: src/initializer/data_provider.cpp | ||
self: core | ||
out: phare_initializer | ||
mode: shared # static singleton dict lives here | ||
|
||
- name: pybind | ||
# parent: base | ||
mode: shared | ||
dep: lang.pybind11 | ||
mod: lang.pybind11 lang.python3 | ||
|
||
- name: dictator | ||
parent: pybind | ||
self: init | ||
src: src/initializer/dictator.cpp | ||
install: build/pybindlibs | ||
out: dictator | ||
|
||
- name: cpp | ||
parent: pybind | ||
# lib: numa | ||
# arg: -DPHARE_WITH_GPU -DKUL_GPU_CUDA | ||
arg: ${gpu.args} | ||
|
||
self: simulator init gpu_base | ||
src: src/python3/cpp_simulator.cpp | ||
install: build/pybindlibs | ||
#test: tests/amr/solvers/ppc/test_gpu_solverppc.cpp | ||
out: cpp | ||
|
||
- name: cpp_etc | ||
parent: pybind | ||
self: simulator | ||
src: src/python3/cpp_etc.cpp | ||
install: build/pybindlibs | ||
out: cpp_etc | ||
arg: -DPHARE_HAS_HIGHFIVE=0 | ||
|
||
- name: py | ||
self: dictator cpp_etc simulator | ||
|
||
- name: test | ||
parent: base | ||
self: init simulator | ||
dep: lang.pybind11 google.test | ||
mod: lang.python3 | ||
inc: . | ||
link: -pthread | ||
|
||
- name: test_diagnostics | ||
parent: test | ||
mode: none | ||
mod: lang.python3 | ||
test: | ||
tests/diagnostic/test-diagnostics_1d.cpp | ||
tests/diagnostic/test-diagnostics_2d.cpp | ||
env: PYTHONPATH=${MKN_ROOT}:${MKN_ROOT}/build/tests/diagnostic:${MKN_ROOT}/build:${MKN_ROOT}/pyphare | ||
|
||
- name: bench | ||
self: core | ||
inc: . tools | ||
dep: google.benchmark | ||
main: tools/bench/core/data/particles/interop.cpp | ||
link: -pthread | ||
|
||
- name: gpu_pusher | ||
parent: test | ||
self: bench | ||
inc: . | ||
dep: mkn.gpu | ||
arg: -DPHARE_WITH_GPU | ||
env: PYTHONPATH=${MKN_ROOT}:${MKN_ROOT}/tools/bench/core/numerics/pusher:${MKN_ROOT}/build:${MKN_ROOT}/pyphare | ||
|
||
- name: rocm_pusher | ||
parent: gpu_pusher | ||
main: tools/bench/core/numerics/pusher/gpu.cpp | ||
arg: -DKUL_GPU_ROCM | ||
env: PYTHONPATH=${MKN_ROOT}:${MKN_ROOT}/tools/bench/core/numerics/pusher:${MKN_ROOT}/build:${MKN_ROOT}/pyphare | ||
|
||
- name: cuda_pusher | ||
parent: gpu_pusher | ||
main: tests/amr/solvers/ppc/test_gpu_solverppc.cpp #tools/bench/core/numerics/pusher/gpu.cpp | ||
arg: -DKUL_GPU_CUDA | ||
inc: subprojects/thrust | ||
env: PYTHONPATH=${MKN_ROOT}:${MKN_ROOT}/tools/bench/core/numerics/pusher:${MKN_ROOT}/build:${MKN_ROOT}/pyphare | ||
|
||
# - name: cuda_bandwidth_test | ||
# main: subprojects/cuda-samples/Samples/bandwidthTest/bandwidthTest.cu | ||
# inc: subprojects/cuda-samples/Common | ||
|
||
- name: c_depositor | ||
test: tools/hw/gpu/bench/depositor.cpp | ||
|
||
- name: mkn.gpu_depositor | ||
dep: mkn.gpu | ||
test: tools/hw/gpu/bench/depositor.mkn.gpu.cpp | ||
|
||
# mkn clean build test run -p mkn.sheath.hip -x res/mkn/hcc.yaml -O | ||
- name: mkn.sheath.hip | ||
dep: mkn.gpu | ||
test: tools/hw/gpu/bench/sheath-gpu.hip.cpp | ||
|
||
- name: mkn.sheath.cuda | ||
dep: mkn.gpu | ||
test: tools/hw/gpu/bench/sheath-gpu.cuda.cpp | ||
|
||
- name: test_core_gpu_mkn | ||
self: core | ||
arg: -DPHARE_WITH_GPU=1 -DPHARE_HAVE_MKN_GPU=1 -DMKN_GPU_CUDA=1 | ||
dep: google.test mkn.gpu nvidia.thrust | ||
main: tests/core/data/test_vector.cpp | ||
|
||
- name: gpu_test | ||
parent: test | ||
self: simulator init | ||
arg: | | ||
-DHAVE_RAJA | ||
-DHAVE_UMPIRE | ||
-DRAJA_ENABLE_CUDA=1 | ||
-DUMPIRE_ENABLE_CUDA=1 | ||
-DPHARE_WITH_GPU=1 | ||
-DPHARE_HAS_HIGHFIVE=1 | ||
-DPHARE_WITH_KUL=1 | ||
-DKUL_GPU_CUDA=1 | ||
test: | ||
tests/core/data/ndarray/test_main.cpp | ||
|
||
# tests/core/numerics/ion_updater/test_updater.cpp | ||
# tests/core/numerics/interpolator/test_main.cpp | ||
# tests/core/data/field/test_field.cpp | ||
# tests/core/data/vecfield/test_main.cpp | ||
# tests/core/data/ions/test_ions.cpp | ||
# tests/core/data/electrons/test_electrons.cpp | ||
# tests/core/numerics/ampere/test_main.cpp | ||
# tests/core/numerics/faraday/test_main.cpp | ||
# tests/core/numerics/ohm/test_main.cpp | ||
|
||
- name: format | ||
mod: | | ||
clang.format{init{style: file, paths: src}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
# wheel might be need to build other deps | ||
wheel | ||
dill | ||
ddt | ||
h5py | ||
|
Oops, something went wrong.