Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
jngrad committed Feb 4, 2025
1 parent adf636d commit d7e14b0
Show file tree
Hide file tree
Showing 43 changed files with 241 additions and 381 deletions.
6 changes: 1 addition & 5 deletions .github/actions/build_and_check/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,9 @@ description: 'Build espresso and run checks'
runs:
using: "composite"
steps:
- run: |
brew install boost boost-mpi fftw
pip3 install -c requirements.txt "cython<3.0" numpy scipy packaging
shell: bash
if: runner.os == 'macOS'
- run: |
export myconfig=maxset with_cuda=false with_gsl=false with_hdf5=false test_timeout=800 check_skip_long=true
if test -d venv; then . venv/bin/activate; fi
bash maintainer/CI/build_cmake.sh
shell: bash
# This is a workaround for the unfortunate interaction of MacOS and OpenMPI 4
Expand Down
21 changes: 14 additions & 7 deletions .github/workflows/push_pull.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ permissions:

jobs:
macos:
runs-on: macos-14
runs-on: macos-15
if: ${{ github.repository == 'espressomd/espresso' }}
steps:
- name: Checkout
Expand All @@ -19,12 +19,15 @@ jobs:
with:
key: macos
save: ${{ github.ref == 'refs/heads/python' }}
- name: Setup Python environment
uses: actions/[email protected]
with:
python-version: '3.12'
- name: Get runner specifications
run: system_profiler SPHardwareDataType
- run: |
brew install boost boost-mpi fftw
python3 -m venv venv
. venv/bin/activate
pip3 install -c requirements.txt "cython<3.0.10" numpy scipy packaging
deactivate
shell: bash
- name: Build and check
uses: ./.github/actions/build_and_check
env:
Expand All @@ -35,7 +38,7 @@ jobs:
debian:
runs-on: ubuntu-latest
container:
image: ghcr.io/espressomd/docker/debian:f7f8ef2c0ca93c67aa16b9f91785492fb04ecc1b-base-layer
image: ghcr.io/jngrad/espresso-docker/debian:b65fb07658b6217546a1da19cde4fcbf89e2ecee-base-layer
credentials:
username: ${{ github.actor }}
password: ${{ secrets.github_token }}
Expand All @@ -57,6 +60,8 @@ jobs:
env:
build_procs: 4
check_procs: 4
CC: 'gcc-12'
CXX: 'g++-12'
myconfig: 'maxset'
with_ccache: 'true'
with_cuda: 'false'
Expand All @@ -74,7 +79,7 @@ jobs:
runs-on: ubuntu-latest
if: ${{ github.repository == 'espressomd/espresso' }}
container:
image: ghcr.io/espressomd/docker/ubuntu-wo-dependencies:f7f8ef2c0ca93c67aa16b9f91785492fb04ecc1b-base-layer
image: ghcr.io/jngrad/espresso-docker/ubuntu-wo-dependencies:b65fb07658b6217546a1da19cde4fcbf89e2ecee-base-layer
credentials:
username: ${{ github.actor }}
password: ${{ secrets.github_token }}
Expand All @@ -96,6 +101,8 @@ jobs:
env:
build_procs: 4
check_procs: 4
CC: 'gcc-13'
CXX: 'g++-13'
myconfig: 'maxset'
with_ccache: 'true'
with_cuda: 'false'
Expand Down
38 changes: 19 additions & 19 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
image: ghcr.io/espressomd/docker/ubuntu:f7f8ef2c0ca93c67aa16b9f91785492fb04ecc1b
image: ghcr.io/jngrad/espresso-docker/ubuntu:b65fb07658b6217546a1da19cde4fcbf89e2ecee

stages:
- prepare
Expand All @@ -17,7 +17,7 @@ stages:

.notification_job_template: &notification_job_definition
<<: *global_job_definition
image: ghcr.io/espressomd/docker/fedora:f7f8ef2c0ca93c67aa16b9f91785492fb04ecc1b
image: ghcr.io/jngrad/espresso-docker/fedora:b65fb07658b6217546a1da19cde4fcbf89e2ecee
variables:
GET_SOURCES_ATTEMPTS: 3
before_script:
Expand Down Expand Up @@ -77,9 +77,9 @@ default:
<<: *global_job_definition
stage: build
variables:
CC: 'gcc-13'
CXX: 'g++-13'
GCOV: 'gcov-13'
CC: 'gcc-14'
CXX: 'g++-14'
GCOV: 'gcov-14'
with_cuda: 'false'
myconfig: 'default'
with_coverage: 'true'
Expand All @@ -98,9 +98,9 @@ maxset:
<<: *global_job_definition
stage: build
variables:
CC: 'gcc-13'
CXX: 'g++-13'
GCOV: 'gcov-13'
CC: 'gcc-14'
CXX: 'g++-14'
GCOV: 'gcov-14'
with_cuda: 'false'
myconfig: 'maxset'
with_coverage: 'true'
Expand All @@ -122,9 +122,9 @@ no_rotation:
<<: *global_job_definition
stage: build
variables:
CC: 'gcc-13'
CXX: 'g++-13'
GCOV: 'gcov-13'
CC: 'gcc-14'
CXX: 'g++-14'
GCOV: 'gcov-14'
with_cuda: 'false'
myconfig: 'no_rotation'
with_coverage: 'true'
Expand All @@ -138,10 +138,10 @@ no_rotation:
- no-cuda
- numa

fedora:40:
fedora:41:
<<: *global_job_definition
stage: build
image: ghcr.io/espressomd/docker/fedora:f7f8ef2c0ca93c67aa16b9f91785492fb04ecc1b
image: ghcr.io/jngrad/espresso-docker/fedora:b65fb07658b6217546a1da19cde4fcbf89e2ecee
variables:
with_cuda: 'false'
with_gsl: 'false'
Expand All @@ -163,9 +163,9 @@ clang-sanitizer:
<<: *global_job_definition
stage: build
variables:
CC: 'clang-18'
CXX: 'clang++-18'
CUDACXX: 'clang++-18'
CC: 'clang-19'
CXX: 'clang++-19'
CUDACXX: 'clang++-19'
myconfig: 'maxset'
with_cuda: 'true'
with_cuda_compiler: 'clang'
Expand Down Expand Up @@ -411,9 +411,9 @@ empty:
<<: *global_job_definition
stage: build
variables:
CC: 'clang-18'
CXX: 'clang++-18'
CUDACXX: 'clang++-18'
CC: 'clang-19'
CXX: 'clang++-19'
CUDACXX: 'clang++-19'
myconfig: 'empty'
with_cuda: 'true'
with_cuda_compiler: 'clang'
Expand Down
24 changes: 16 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ if(POLICY CMP0167)
# use BoostConfig.cmake shipped with Boost 1.70+ instead of the one in CMake
cmake_policy(SET CMP0167 NEW)
endif()
if(POLICY CMP0169)
# use deprecated FetchContent_Populate function for h5xx dependency
cmake_policy(SET CMP0169 OLD)
endif()
message(STATUS "CMake version: ${CMAKE_VERSION}")
# CMake modules/macros are in a subdirectory to keep this file cleaner
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
Expand All @@ -48,9 +52,9 @@ macro(espresso_minimal_compiler_version)
endif()
endmacro()

espresso_minimal_compiler_version("GNU" 10.5.0)
espresso_minimal_compiler_version("Clang" 14.0.0)
espresso_minimal_compiler_version("AppleClang" 14.0.0)
espresso_minimal_compiler_version("GNU" 12.2.0)
espresso_minimal_compiler_version("Clang" 18.1.0)
espresso_minimal_compiler_version("AppleClang" 16.0.0)
espresso_minimal_compiler_version("IntelLLVM" 2023.1)

set(UNSUPPORTED_COMPILERS "Intel;MSVC")
Expand Down Expand Up @@ -117,7 +121,7 @@ FetchContent_Declare(
FetchContent_Declare(
caliper
GIT_REPOSITORY https://github.com/LLNL/Caliper.git
GIT_TAG v2.12.0
GIT_TAG v2.12.1
)
# cmake-format: on

Expand Down Expand Up @@ -237,8 +241,6 @@ if(ESPRESSO_BUILD_WITH_CUDA)
include(CheckLanguage)
enable_language(CUDA)
check_language(CUDA)
espresso_minimal_compiler_version("GNU" 11.4.0)
espresso_minimal_compiler_version("Clang" 17.0.0)
set(CMAKE_CUDA_STANDARD 20)
set(CMAKE_CUDA_STANDARD_REQUIRED ON)
set(ESPRESSO_MINIMAL_CUDA_VERSION 12.0)
Expand Down Expand Up @@ -767,15 +769,21 @@ if(ESPRESSO_BUILD_WITH_WALBERLA)
set(BUILD_SHARED_LIBS ${ESPRESSO_BUILD_SHARED_LIBS_DEFAULT})
set(CMAKE_SHARED_LIBRARY_PREFIX "${ESPRESSO_SHARED_LIBRARY_PREFIX}")
endif()
# patching
target_compile_options(
blockforest
PRIVATE
$<$<AND:$<CXX_COMPILER_ID:GNU>,$<VERSION_GREATER_EQUAL:$<CXX_COMPILER_VERSION>,14>>:-Wno-alloc-size>
)
set(WALBERLA_LIBS
walberla::core walberla::domain_decomposition walberla::blockforest
walberla::boundary walberla::field walberla::lbm walberla::timeloop
walberla::vtk)
if(WALBERLA_BUILD_WITH_FFTW)
set(WALBERLA_LIBS ${WALBERLA_LIBS} walberla::fft)
list(APPEND WALBERLA_LIBS walberla::fft)
endif()
if(WALBERLA_BUILD_WITH_CUDA)
set(WALBERLA_LIBS ${WALBERLA_LIBS} walberla::gpu)
list(APPEND WALBERLA_LIBS walberla::gpu)
endif()
set(WALBERLA_LIBS_EXPORT
${WALBERLA_LIBS}
Expand Down
3 changes: 2 additions & 1 deletion doc/sphinx/Readme.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ How to get started with Sphinx

.. code-block:: bash
pip3 install --user --upgrade 'sphinx>=2.3.0,!=3.0.0' 'sphinxcontrib-bibtex>=0.3.5'
python3 -m pip install -c requirements.txt \
sphinx sphinx-toggleprompt sphinxcontrib-bibtex numpydoc pybtex
#. Compile the ``sphinx`` target in your build directory (that can take some
time since we depend on finishing the build of the interface):
Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx/ek.rst
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ Start by installing the code generator dependencies:

.. code-block:: bash
python3 -m pip install --user -c requirements.txt numpy sympy lbmpy pystencils islpy
python3 -m pip install -c requirements.txt numpy sympy lbmpy pystencils islpy
Next, edit the code generator script to configure new kernels, then execute it:

Expand Down
13 changes: 6 additions & 7 deletions doc/sphinx/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ To install the ZnDraw visualizer:

.. code-block:: bash
python3 -m pip install --user -c requirements.txt 'zndraw==0.4.6'
python3 -m pip install -c requirements.txt 'zndraw==0.4.6'
.. _Nvidia GPU acceleration:

Expand Down Expand Up @@ -207,7 +207,7 @@ To generate the Sphinx documentation, install the following packages:

.. code-block:: bash
python3 -m pip install --user -c requirements.txt \
python3 -m pip install -c requirements.txt \
sphinx sphinxcontrib-bibtex sphinx-toggleprompt
To generate the Doxygen documentation, install the following packages:
Expand Down Expand Up @@ -250,15 +250,14 @@ to use, we recommend installing JupyterLab:

.. code-block:: bash
python3 -m pip install --user -c requirements.txt \
nbformat nbconvert jupyterlab
python3 -m pip install -c requirements.txt \
jupyterlab>=4.3 nbformat nbconvert lxml[html_clean]
If you prefer the look and feel of Jupyter Classic, install the following:
If you prefer the look and feel of Jupyter Classic, install the following extra package:

.. code-block:: bash
python3 -m pip install --user -c requirements.txt \
nbformat nbconvert jupyterlab nbclassic
python3 -m pip install -c requirements.txt nbclassic
Alternatively, to use VS Code Jupyter, install the following extensions:

Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx/lb.rst
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,7 @@ Start by installing the code generator dependencies:

.. code-block:: bash
python3 -m pip install --user -c requirements.txt numpy sympy lbmpy pystencils islpy
python3 -m pip install -c requirements.txt numpy sympy lbmpy pystencils islpy
Next, edit the code generator script to configure new kernels, then execute it:

Expand Down
4 changes: 2 additions & 2 deletions doc/sphinx/running.rst
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ Valgrind
.. code-block:: bash
sudo apt install valgrind kcachegrind graphviz
python3 -m pip install --user gprof2dot
python3 -m pip install gprof2dot
The Valgrind [2]_ :cite:`nethercote07a,nethercote03a` framework brings several
tools to examine a program runtime performance.
Expand Down Expand Up @@ -1066,7 +1066,7 @@ kernprof

.. code-block:: bash
python3 -m pip install --user line_profiler
python3 -m pip install line_profiler
kernprof [8]_ :cite:`misc-kernprof` is a low-overhead Python profiler.
It supports two instrumentation modes: ``line_profile`` and ``cProfile``.
Expand Down
Loading

0 comments on commit d7e14b0

Please sign in to comment.