(Note: Requires Julia >= 1.11)
julia --project -e 'using Pkg; Pkg.instantiate()'
To get the mpiexecjl
driver run:
julia --project -e 'using MPI; MPI.install_mpiexecjl()'
Afterwards, put '$HOME/.julia/bin' on PATH
, e.g.
export PATH=$HOME/.julia/bin:$PATH
(If you don't want to modify PATH
use $HOME/.julia/bin/mpiexecjl
directly to run the MPI code.)
If you want to use a system MPI run the following:
julia --project -e 'using MPIPreferences; MPIPreferences.use_system_binary()'
No MPI:
julia nstream.jl 10 1000000
With MPI:
mpiexecjl -n 4 julia --project nstream-mpi.jl 10 1000000