<div>I'm not sure what it can be wrong...</div>I suggest to compile COSMA outside the toolchain with two steps: only CPU and test it, then if it works move to GPU compilation. <div>What's the error you get with COSMA?<br /></div><div><br /></div><div>I'm surprised you get an error with Sirius, unless you specifically use it if should give any error...<br /></div><div><br /></div><div><br /></div><div><br /></div><div class="gmail_quote"><div dir="auto" class="gmail_attr">Il giorno sabato 8 aprile 2023 alle 01:26:22 UTC+2 Nathan Keilbart ha scritto:<br/></div><blockquote class="gmail_quote" style="margin: 0 0 0 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div>Thanks Alfio. Sorry for my late reply. It seems something in my environment was keeping that from being detected correctly. My scripts now detect everything correctly and after finding certain libraries that wouldn't build I was finally able to get a working binary. One strange issue is that the -ldl flag was needed when compiling the parallel binary. Not sure if this is normally detected but for my system and inputs I was providing it didn't do it so I simply added it to the arch files.<br></div><div><br></div><div>Initially, I was getting a cuda memory issue when running my test system of 300 atoms on one node with four GPUs but I have since resubmitted the job several times and it appears to be working. I'm not sure if I was just getting a bad node or something. <br></div><div><br></div><div>As I mentioned, I had to disable quite a few libraries. They install just fine according to the terminal but when I go to compile the binaries it causes them to misbehave and crash before even doing the initial SCF loop. Here are the flags I used.</div><div><br></div><div></div><div>./install_cp2k_toolchain.sh --install-all --with-cmake=system --with-openmpi=system --with-gcc=system --with-quip=no --with-libtorch=no --with-plumed=no --with-cosma=no --with-sirius=no --enable-cuda --gpu-ver=V100</div><div><br></div><div>In your opinion, would I get any more of a speed up by debugging this issue? I'm primarily concerned with the cosma and sirius libraries. Once again, thank you for your help. I'm working on an intel system and have a working binary but might have some questions as I'm seeing very poor scaling when I use multiple nodes.<br></div><div class="gmail_quote"><div dir="auto" class="gmail_attr">On Thursday, March 30, 2023 at 9:35:52 PM UTC-7 Alfio Lazzaro wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">There is still something wrong in your local_cuda.psmp file.<div>In your output above I cannot find the flag `-D__parallel` . Isee only the followings:</div><div><br></div><div>-D__OFFLOAD_CUDA -D__DBCSR_ACC   -D__FFTW3  -D__LIBINT -D__LIBXC -D__SCALAPACK -D__COSMA -D__ELPA -D__ELPA_NVIDIA_GPU -D__GSL -D__HDF5 -D__LIBVDWXC -D__SPGLIB -D__LIBVORI -D__SPFFT  -D__OFFLOAD_GEMM  -D__SPLA -D__SIRIUS    -D__CUDA</div><div><br></div><div>So my guess is that the toolchain was not able to recognize MPI (no idea why). Could you add -D__parallel on top of those flags?<br><br></div><div class="gmail_quote"><div dir="auto" class="gmail_attr">Il giorno venerdì 31 marzo 2023 alle 00:08:29 UTC+2 Nathan Keilbart ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>Thank Alfio. I wasn't sure what file was controlling that. I updated the file to have those compilers and then did a make realclean. Afterwards, I am now getting this error:</div><div><br></div><div>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:192:19:<br><br>             gcd_max = -1<br>                   1<br>Error: Symbol 'gcd_max' at (1) has no IMPLICIT type<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:193:18:<br><br>             DO ipe = 1, CEILING(SQRT(REAL(npe, dp)))<br>                  1<br>Error: Symbol 'ipe' at (1) has no IMPLICIT type<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:194:18:<br><br>                jpe = npe/ipe<br>                  1<br>Error: Symbol 'jpe' at (1) has no IMPLICIT type<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:185:29:<br><br>          my_blacs_grid_layout = BLACS_GRID_SQUARE<br>                             1<br>Error: Symbol 'my_blacs_grid_layout' at (1) has no IMPLICIT type; did you mean 'blacs_grid_layout'?<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:221:25:<br><br>       my_blacs_repeatable = .FALSE.<br>                         1<br>Error: Symbol 'my_blacs_repeatable' at (1) has no IMPLICIT type; did you mean 'blacs_repeatable'?<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:213:18:<br><br>       my_row_major = .TRUE.<br>                  1<br>Error: Symbol 'my_row_major' at (1) has no IMPLICIT type; did you mean 'row_major'?<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:174:11:<br><br>       npcol = 1<br>           1<br>Error: Symbol 'npcol' at (1) has no IMPLICIT type; did you mean 'ipcol'?<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:175:9:<br><br>       npe = blacs_env%n_pid<br>         1<br>Error: Symbol 'npe' at (1) has no IMPLICIT type<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:173:11:<br><br>       nprow = 1<br>           1<br>Error: Symbol 'nprow' at (1) has no IMPLICIT type; did you mean 'iprow'?<br>/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/src/fm/cp_blacs_env.F:188:22:<br><br>          SELECT CASE (my_blacs_grid_layout)<br>                      1<br>Error: Argument of SELECT statement at (1) cannot be UNKNOWN<br>make[3]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/Makefile:519: cp_blacs_env.o] Error 1<br>make[2]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/Makefile:146: all] Error 2</div><div><br>make[1]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/Makefile:128: psmp] Error 2<br>make: *** [Makefile:123: all] Error 2</div><br><div class="gmail_quote"><div dir="auto" class="gmail_attr">On Thursday, March 30, 2023 at 12:22:43 AM UTC-7 Alfio Lazzaro wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">There is no relation with the DBCSR compilation itself, you see a problem in DBCSR simply because it is the first to compile in CP2K.<div>The error message is:</div><div><br></div><div>/bin/sh: c: command not found<br></div><div><br></div><div>and indeed you are using the command</div><div><br></div><div>c -fno-omit-frame-pointer -fopenmp -g -mtune=native  -O3 -funroll-loops    ...<br></div><div><br></div><div>for compiling, therefore there is something wrong in the compiler call.</div><div>I think the problem is that the local_cuda.psmp file has something wrong in the definition of the compilers, namely the lines</div><div><br></div><div>CC             := mpicc<br>FC             := mpif90<br>LD             := mpif90<br>AR             := ar -r<br></div><div><br></div><div>could you check if they are linking to the rights commands?</div><div><br></div><div><br></div><div><br><br></div><div class="gmail_quote"><div dir="auto" class="gmail_attr">Il giorno giovedì 30 marzo 2023 alle 03:12:26 UTC+2 Nathan Keilbart ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>Hello everyone,</div><div><br></div><div>I've been working on installing CP2K on a system with IBM Power9 processors and Nvidia V100 GPUs. I'm using the toolchain with these options:</div><div><br></div><div>./install_cp2k_toolchain.sh -j --with-cmake=system --mpi-mode=openmpi --enable-cuda --gpu-ver=V100</div><div><br></div><div>It installs all the dependencies without any errors so that I copy over the files to the arch folder and then source the setup file followed by</div><div><br></div><div>make -j ARCH=local_cuda VERSION=psmp</div><div><br></div><div>The following is some of the last lines of output<br></div><div><br></div><div>/usr/bin/env python3 /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/tools/build_utils/fypp/bin/fypp -n --line-marker-format=gfortran5 /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/src/tensors/dbcsr_tensor_test.F dbcsr_tensor_test.F90<br>c -fno-omit-frame-pointer -fopenmp -g -mtune=native  -O3 -funroll-loops    -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/openblas-0.3.21/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/fftw-3.3.10/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/libint-v2.6.0-cp2k-lmax-5/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/libxc-6.0.0/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/COSMA-2.6.2/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/elpa-2022.11.001/nvidia/include/elpa_openmp-2022.11.001/modules' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/elpa-2022.11.001/nvidia/include/elpa_openmp-2022.11.001/elpa' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/gsl-2.7/include' -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/hdf5-1.12.0/include -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/libvdwxc-0.4.0/include -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/spglib-1.16.2/include -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/SpFFT-1.0.6/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/SpLA-1.5.4/include/spla' -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/sirius-7.3.2/include/cuda -fbacktrace -ffree-form -fimplicit-none -std=f2008  -Werror=aliasing -Werror=ampersand -Werror=c-binding-type -Werror=intrinsic-shadow -Werror=intrinsics-std -Werror=line-truncation -Werror=tabs -Werror=target-lifetime -Werror=underflow -Werror=unused-but-set-variable -Werror=unused-variable -Werror=unused-dummy-argument -Werror=conversion -Werror=zerotrip -Wno-maybe-uninitialized -Wuninitialized -Wuse-without-only  -D__OFFLOAD_CUDA -D__DBCSR_ACC   -D__FFTW3  -D__LIBINT -D__LIBXC -D__SCALAPACK -D__COSMA -D__ELPA -D__ELPA_NVIDIA_GPU -D__GSL -D__HDF5 -D__LIBVDWXC -D__SPGLIB -D__LIBVORI -D__SPFFT  -D__OFFLOAD_GEMM  -D__SPLA -D__SIRIUS    -D__CUDA -D__SHORT_FILE__="\"dbcsr_tensor_test.F\"" -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/src/tensors/' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/src' dbcsr_tensor_test.F90 <br>/bin/sh: c: command not found<br>make[4]: [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/build_dbcsr//Makefile:258: dbcsr_tensor_test.o] Error 127 (ignored)<br>/usr/bin/env python3 /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/tools/build_utils/fypp/bin/fypp -n --line-marker-format=gfortran5 /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/src/tensors/dbcsr_tensor_api.F dbcsr_tensor_api.F90<br>c -fno-omit-frame-pointer -fopenmp -g -mtune=native  -O3 -funroll-loops    -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/openblas-0.3.21/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/fftw-3.3.10/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/libint-v2.6.0-cp2k-lmax-5/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/libxc-6.0.0/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/COSMA-2.6.2/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/elpa-2022.11.001/nvidia/include/elpa_openmp-2022.11.001/modules' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/elpa-2022.11.001/nvidia/include/elpa_openmp-2022.11.001/elpa' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/gsl-2.7/include' -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/hdf5-1.12.0/include -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/libvdwxc-0.4.0/include -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/spglib-1.16.2/include -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/SpFFT-1.0.6/include' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/SpLA-1.5.4/include/spla' -I/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/tools/toolchain/install/sirius-7.3.2/include/cuda -fbacktrace -ffree-form -fimplicit-none -std=f2008  -Werror=aliasing -Werror=ampersand -Werror=c-binding-type -Werror=intrinsic-shadow -Werror=intrinsics-std -Werror=line-truncation -Werror=tabs -Werror=target-lifetime -Werror=underflow -Werror=unused-but-set-variable -Werror=unused-variable -Werror=unused-dummy-argument -Werror=conversion -Werror=zerotrip -Wno-maybe-uninitialized -Wuninitialized -Wuse-without-only  -D__OFFLOAD_CUDA -D__DBCSR_ACC   -D__FFTW3  -D__LIBINT -D__LIBXC -D__SCALAPACK -D__COSMA -D__ELPA -D__ELPA_NVIDIA_GPU -D__GSL -D__HDF5 -D__LIBVDWXC -D__SPGLIB -D__LIBVORI -D__SPFFT  -D__OFFLOAD_GEMM  -D__SPLA -D__SIRIUS    -D__CUDA -D__SHORT_FILE__="\"dbcsr_tensor_api.F\"" -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/src/tensors/' -I'/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/dbcsr/src' dbcsr_tensor_api.F90 <br>/bin/sh: c: command not found<br>make[4]: [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/build_dbcsr//Makefile:258: dbcsr_tensor_api.o] Error 127 (ignored)<br>Updating archive /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/lib/local_cuda/psmp/exts/dbcsr/libdbcsr.a<br>ar: creating /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/lib/local_cuda/psmp/exts/dbcsr/libdbcsr.a<br>ar: dbcsr_cuda_profiling.o: No such file or directory<br>make[4]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/build_dbcsr//Makefile:330: /usr/gapps/qsg/codes/cp2k/lassen/v2023.1/lib/local_cuda/psmp/exts/dbcsr/libdbcsr.a] Error 1<br>make[3]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/build_dbcsr/Makefile:179: libdbcsr] Error 2<br>make[2]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/exts/Makefile.inc:38: dbcsr] Error 2<br>make[1]: *** [/usr/gapps/qsg/codes/cp2k/lassen/v2023.1/Makefile:128: psmp] Error 2<br>make: *** [Makefile:123: all] Error 2</div><div><br></div><div>It seems that it is having issues with the DBCSR module. I initially had an issue with this because I seemed to have left off the --recursive option and after making sure my git clone had that it at least let me build most of the serial version. It at least gave me the cp2k.sopt binary and it seems to at least take inputs. I didn't have a chance to test it too much yet. When I got this binary I had done <br></div><div><br></div><div>make -j ARCH=local_cuda VERSION="ssmp sdbg psmp pdbg"</div><div><br></div><div>as suggested.</div><div><br></div><div>Also, I've attempted to install with spack by using</div><div><br></div><div>spack install cp2k@2023.1+cosma+cuda+elpa+libint+libxc+mpi+openmp+pexsi+plumed+sirius+spglib smm=blas cuda_arch=70</div><div><br></div><div>These are some of the last lines of output</div><div><br></div><div> >> 4028    collect2: error: ld returned 1 exit status<br>  >> 4029    collect2: error: ld returned 1 exit status<br>  >> 4030    make[3]: *** [/tmp/keilbart/spack-stage/spack-stage-cp2k-2023.1-24dhoyt24tbnn4d423glgoeqqquibmb6/spack-src/obj/linux-rhel7-power9le-gcc/psmp/<br>             all.dep:178: /tmp/keilbart/spack-stage/spack-stage-cp2k-2023.1-24dhoyt24tbnn4d423glgoeqqquibmb6/spack-src/exe/linux-rhel7-power9le-gcc/cp2k.p<br>             smp] Error 1<br>     4031    make[3]: *** Waiting for unfinished jobs....<br>  >> 4032    make[3]: *** [/tmp/keilbart/spack-stage/spack-stage-cp2k-2023.1-24dhoyt24tbnn4d423glgoeqqquibmb6/spack-src/obj/linux-rhel7-power9le-gcc/psmp/<br>             all.dep:194: /tmp/keilbart/spack-stage/spack-stage-cp2k-2023.1-24dhoyt24tbnn4d423glgoeqqquibmb6/spack-src/exe/linux-rhel7-power9le-gcc/libcp2<br>             k_unittest.psmp] Error 1<br>  >> 4033    make[2]: *** [/tmp/keilbart/spack-stage/spack-stage-cp2k-2023.1-24dhoyt24tbnn4d423glgoeqqquibmb6/spack-src/Makefile:146: all] Error 2<br>  >> 4034    make[1]: *** [/tmp/keilbart/spack-stage/spack-stage-cp2k-2023.1-24dhoyt24tbnn4d423glgoeqqquibmb6/spack-src/Makefile:128: psmp] Error 2<br>  >> 4035    make: *** [Makefile:123: all] Error 2</div><div><br></div><div>Finally, I also have some intel machines that I'm attempting to build on and having issues as well but we can start with the IBM machine as we're hoping to accelerate the simulations with the GPU.</div><div><br></div><div>Please let me know what other information I can provide. Thank you.</div><div><br>Nathan<br></div></blockquote></div></blockquote></div></blockquote></div></blockquote></div></blockquote></div>

<p></p>

-- <br />
You received this message because you are subscribed to the Google Groups "cp2k" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="mailto:cp2k+unsubscribe@googlegroups.com">cp2k+unsubscribe@googlegroups.com</a>.<br />
To view this discussion on the web visit <a href="https://groups.google.com/d/msgid/cp2k/d06a52ce-0e53-403a-a79a-bec58c9ab8f1n%40googlegroups.com?utm_medium=email&utm_source=footer">https://groups.google.com/d/msgid/cp2k/d06a52ce-0e53-403a-a79a-bec58c9ab8f1n%40googlegroups.com</a>.<br />