Skip to content

Instantly share code, notes, and snippets.

@erikzenker
Last active May 20, 2016 12:22
Show Gist options
  • Save erikzenker/84c136aa6d58b087791c to your computer and use it in GitHub Desktop.
Save erikzenker/84c136aa6d58b087791c to your computer and use it in GitHub Desktop.
#!/usr/bin/env sh
git clone https://github.com/psychocoderHPC/picongpu-alpaka.git
cd picongpu-alpaka
git checkout topic-cupla
cd ..
git clone https://github.com/psychocoderHPC/alpaka.git
cd alpaka
git checkout topic-picongpu-alpaka
cd ..
git clone https://github.com/psychocoderHPC/cupla.git
cd cupla
git checkout topic-dualAccelerators
git submodule init
git submodule update
cd ..
export ALPAKA_ROOT=~/projects/alpaka/
export CUPLA_ROOT=~/projects/cupla/
mkdir ~/projects/pic
export PICHOME=~/projects/pic
export PICSRC=~/projects/picongpu-alpaka
export PATH=$PATH:$PICSRC/src/tools/bin
# Set correct cmake binary
export PATH=~/libs/cmake/bin:$PATH:~/libs/cmake/bin/
module load mpi/openmpi/1.10.0/gcc/4.9.2
export CXX=gcc-4.9
mkdir -p $PICHOME/build $PICHOME/paramSets $PICHOME/paramSets $PICHOME/runs
# Create parameter set
cd pic
$PICSRC/createParameterSet $PICSRC/examples/KelvinHelmholtz/ $PICHOME/paramSets/ki/case001
# Use kelvin helmholtz example
cd $PICHOME/build
$PICSRC/configure -c "-DBOOST_ROOT=~/libs/boost/include/boost-1_60/ -Boost_LIBRARY_DIR=~/libs/boost/lib" $PICHOME/paramSets/ki/case001
# Set Accelerator
ccmake .
make install
# CCmake Block parallel accelerator
# CCmake Release mode
# CCmake CMAKE_CXX_FLAGS -ffast-math -march=native -funroll-loops -fopt-info-loop-optimized=vec.opt
cd $PICHOME/paramSets/ki/case001
mpiexec --bind-to none -n 4 --mca mpi_leave_pinned 0 submit/gpu_numa_aware ./bin/picongpu -d 4 1 1 -g 128 128 128 -s 100 --periodic 1 1 1 -p 1
# Experiements with number of threads, number of ranks per node
# memory.param set SuperCellSize can influence performance
# numactl optimization
# CCmake CUDA accelerator
# Compile with xlc
export CXX=xlc++
export CC=xlc
# Fix FindBoost.cmake by seting _boost_COMPILER to xlc (line 471)
# Pull Request on githun: https://github.com/Kitware/CMake/pull/229
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment