Skip to content

Commit deb69bf

Browse files
committed
doc(README): describe flang multi-image workflow
1 parent 98509cf commit deb69bf

2 files changed

Lines changed: 34 additions & 1 deletion

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ commands in the table below will build and run the Julienne test suite. With
201201

202202
Compiler/Runtime |Tested Versions|Run Type|`bash` build/test commands (`num_images()==2`)
203203
------------------|---------------|--------|----------------------------------------------
204-
LLVM/[Caffeine] |22 |parallel|please contact fortran@lbl.gov
204+
LLVM/[Caffeine] |22 |parallel| Please consult the [parallelism documentation](./doc/parallelism/README.md).
205205
LLVM/[Caffeine] |20-22 |serial |`fpm test --compiler flang-new --flag -O3`
206206
LLVM/[Caffeine] |19 |serial |`fpm test --compiler flang-new --flag "-O3 -mmlir -allow-assumed-rank"`
207207
NAG |7.2, Build 7235|parallel|`NAGFORTRAN_NUM_IMAGES=2 fpm test --compiler nagfor --flag "-fpp -O3 -coarray"`

doc/parallelism/README.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
Parallel Testing with Caffeine
2+
==============================
3+
4+
LLVM Flang 22 supports the native Fortran parallel programming model used by
5+
Julienne: features that enable launching multiple images, which are instances
6+
of a program. To launch multi-image runs, Flang generates calls to the
7+
Parallel Runtime Interface for Fortran [(PRIF)](https://go.lbl.gov/prif).
8+
Using these features requires linking programs to a PRIF implementation such
9+
as [Caffeine](https://go.lbl.gov/caffeine).
10+
11+
Rough Workflow
12+
--------------
13+
The steps below are intended more for reading rather than for running. Steps
14+
like these worked recently on a macOS 15.5 system with Apple Silicon, with the
15+
Homebrew package manager installed, and with `$HOME/.local/` in the `PATH`.
16+
```bash
17+
brew install gcc@14
18+
git clone -b gcc14.3.0-julienne3.2.0-caffeine0.6.0 https://github.com/BerkeleyLab/flang-testing-project.git
19+
git clone https://github.com/rouson/handy-dandy
20+
chmod u+x handy-dandy/src/fresh-llvm-build.sh
21+
cd flang-testing-project
22+
./handy-dandy/src/fresh-llvm-build.sh --prefix=$HOME/.local
23+
cd ..
24+
git clone https://github.com/BerkeleyLab/caffeine.git
25+
cd caffeine
26+
FC=flang-new CC=clang CXX=clang++ ./install.sh --prefix=$HOME/.local
27+
cd ..
28+
git clone https://github.com/berkeleylab/julienne
29+
cd julienne
30+
fpm test --compiler flang-new --flag -O3 --link-flag <link-to-caffeine>
31+
```
32+
If something similar to the above workflow does not work for you, please
33+
contact fortran@lbl.gov for assistance.

0 commit comments

Comments
 (0)