Skip to content

About

Almost trivial distributed parallelization of stencil-based GPU and CPU applications on a regular staggered grid

Topics

Resources

Stars

207 stars

Watchers

10 watching

Forks

Latest commit

 

History

564 Commits

Folders and files

Repository files navigation

ImplicitGlobalGrid.jl ImplicitGlobalGrid.jl

Docs stable Docs dev CI Daint GH200 Beverin MI250 Beverin MI300 Coverage DOI

ImplicitGlobalGrid renders the distributed parallelization of stencil-based GPU and CPU applications on a regular staggered grid almost trivial and enables close to ideal weak scaling on thousands of GPUs. The global grid is created implicitly from the number of processes: write the code for one GPU/CPU, and as little as three functions can be enough to turn it into a massively scaling Multi-GPU/CPU application. Halo updates rely on MPI.jl and can leverage CUDA-aware or ROCm-aware MPI; 1-D, 2-D and 3-D grids are supported. Background, contributors and references are in the documentation.

Documentation

Usage, examples and the API reference are found in the documentation:

  • stable: documentation of the latest release;
  • dev: documentation of the main branch.

Installation

import Pkg; Pkg.add("ImplicitGlobalGrid")

Usage

using ImplicitGlobalGrid                 # Import CUDA or AMDGPU before ImplicitGlobalGrid to activate GPU support.

nx, ny, nz = 64, 64, 64
me, dims = init_global_grid(nx, ny, nz)  # Create the implicit global grid (and initialize MPI).
A = zeros(nx, ny, nz)
# ... computations on the local grid ...
update_halo!(A)                          # Update the halo of A.
finalize_global_grid()                   # Finalize the implicit global grid (and MPI).

Launch the script with the MPI launcher (see the MPI.jl documentation). A complete application is shown in the 50-lines Multi-GPU example.

Questions, comments and discussions

Please post on Julia Discourse in the GPU topic or the Julia at Scale topic, or in the #gpu or #hpc channels on the Julia Slack. Contributions are welcome; please open an issue to discuss your idea beforehand.

Funding

The development of this package is supported by the GPU4GEO and ∂GPU4GEO PASC projects. More information about the GPU4GEO project can be found on the GPU4GEO website.

About

Almost trivial distributed parallelization of stencil-based GPU and CPU applications on a regular staggered grid

Topics

Resources

Stars

207 stars

Watchers

10 watching

Forks

Releases

Used by

Contributors

Languages