From b58a1508faa9ef1d25ed2d1711e7183c09e0b266 Mon Sep 17 00:00:00 2001 From: Peter Boyle Date: Thu, 21 May 2026 13:25:13 -0700 Subject: [PATCH 1/4] Perlmutter cuda version update --- systems/Perlmutter/config-command | 6 +++--- systems/Perlmutter/sourceme.sh | 6 ++++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/systems/Perlmutter/config-command b/systems/Perlmutter/config-command index 30b17b4e..730cb8c1 100644 --- a/systems/Perlmutter/config-command +++ b/systems/Perlmutter/config-command @@ -1,12 +1,12 @@ DIR=`pwd` -PREFIX=$HOME/DDHMC/Grid/systems/Prerequisites/install/ + ../../configure \ --enable-comms=mpi \ --enable-simd=GPU \ --enable-shm=nvlink \ --enable-gen-simd-width=64 \ - --with-gmp=$PREFIX \ - --with-mpfr=$PREFIX \ + --with-gmp=$GMP \ + --with-mpfr=$MPFR \ --enable-accelerator=cuda \ --disable-fermion-reps \ --disable-unified \ diff --git a/systems/Perlmutter/sourceme.sh b/systems/Perlmutter/sourceme.sh index 6d09b1c9..1e4d2de6 100644 --- a/systems/Perlmutter/sourceme.sh +++ b/systems/Perlmutter/sourceme.sh @@ -1,4 +1,6 @@ - export CRAY_ACCEL_TARGET=nvidia80 +source /global/homes/p/pboyle/spack/share/spack/setup-env.sh +export MPFR=`spack find --paths mpfr | grep mpfr | cut -c 13-` +export GMP=`spack find --paths gmp | grep gmp | cut -c 12-` -module load PrgEnv-gnu cpe-cuda cudatoolkit/11.4 +module load PrgEnv-gnu cpe-cuda cudatoolkit/12.0 From bf5fcdc8600adef00857d4600bbb8cd551654f8c Mon Sep 17 00:00:00 2001 From: Peter Boyle Date: Wed, 27 May 2026 16:05:37 -0400 Subject: [PATCH 2/4] Ease of use for std::complex interchangable with thrust --- Grid/simd/Simd.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Grid/simd/Simd.h b/Grid/simd/Simd.h index 428981fa..be60a99a 100644 --- a/Grid/simd/Simd.h +++ b/Grid/simd/Simd.h @@ -113,6 +113,14 @@ accelerator_inline RealD adj(const RealD & r){ return r; } accelerator_inline ComplexD adj(const ComplexD& r){ return(conjugate(r)); } accelerator_inline ComplexF adj(const ComplexF& r ){ return(conjugate(r)); } +#if defined(GRID_CUDA) || defined(GRID_HIP) +//Provide for convenience +accelerator_inline std::complex conjugate(const std::complex& r){ return(conj(r)); } +accelerator_inline std::complex conjugate(const std::complex& r) { return(conj(r)); } +accelerator_inline std::complex adj(const std::complex& r) { return(conj(r)); } +accelerator_inline std::complex adj(const std::complex& r) { return(conj(r)); } +#endif + accelerator_inline RealF real(const RealF & r){ return r; } accelerator_inline RealD real(const RealD & r){ return r; } accelerator_inline RealF real(const ComplexF & r){ return r.real(); } From b0c99f876e3638138195680ae8ca63647e70b409 Mon Sep 17 00:00:00 2001 From: Peter Boyle Date: Wed, 27 May 2026 16:16:55 -0400 Subject: [PATCH 3/4] Configure on mac update --- systems/mac-arm/sourceme.sh | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 systems/mac-arm/sourceme.sh diff --git a/systems/mac-arm/sourceme.sh b/systems/mac-arm/sourceme.sh new file mode 100644 index 00000000..23a392ee --- /dev/null +++ b/systems/mac-arm/sourceme.sh @@ -0,0 +1,11 @@ +source /Users/peterboyle/QCD//Spack/spack//share/spack/setup-env.sh + +export FFTW=`spack find --paths fftw | grep ^fftw | awk '{print $2}' ` +#export HDF5=`spack find --paths hdf5+cxx | grep ^hdf5 | awk '{print $2}' ` +export CLIME=`spack find --paths c-lime | grep ^c-lime | awk '{print $2}' ` +export MPFR=`spack find --paths mpfr | grep ^mpfr | awk '{print $2}' ` +export OPENSSL=`spack find --paths openssl | grep openssl | awk '{print $2}' ` +export GMP=`spack find --paths gmp | grep ^gmp | awk '{print $2}' ` + +export LD_LIBRARY_PATH=$MPFR/lib:$LD_LIBRARY_PATH +export LD_LIBRARY_PATH=$GMP/lib:$LD_LIBRARY_PATH From 86c7f291835a3f88fcd5569974f18a40d59f9950 Mon Sep 17 00:00:00 2001 From: Peter Boyle Date: Wed, 27 May 2026 16:19:33 -0400 Subject: [PATCH 4/4] Config command update --- systems/mac-arm/config-command-mpi | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/systems/mac-arm/config-command-mpi b/systems/mac-arm/config-command-mpi index bb261fe6..9ddf4997 100644 --- a/systems/mac-arm/config-command-mpi +++ b/systems/mac-arm/config-command-mpi @@ -3,7 +3,10 @@ CXX=mpicxx ../../configure \ --enable-simd=GEN \ --enable-comms=mpi-auto \ - --enable-Sp=yes \ + --enable-Sp=no \ + --disable-fermion-reps \ + --disable-gparity \ + --with-fftw=$FFTW \ --enable-unified=yes \ --prefix /Users/peterboyle/QCD/vtk/Grid/install \ --with-lime=$CLIME \