using mkl scalapack option gives errors

Questions regarding the compilation of VASP on various platforms: hardware, compilers and libraries, etc.


Moderators: Global Moderator, Moderator

Locked
Message
Author
User avatar
paulfons
Jr. Member
Jr. Member
Posts: 99
Joined: Sun Nov 04, 2012 2:40 am
License Nr.: 5-1405
Location: Yokohama, Japan
Contact:

using mkl scalapack option gives errors

#1 Post by paulfons » Mon Feb 17, 2025 7:31 am

I have made some progress on compiling Vasp 6.5.0 using the Intel oneapi 2025.0.4 20241205 compiler. There are now no errors until the final linking step (HDF5 include, but no other options), but a cascade of errors occurs due to undefined references to scalapack.

I have attached the output from "make" (nohup.out) as well as the "makefile.include" file I used (from the arch directory with only a few changes to update the new compiler names in the latest oneapi.
The instructions in makefile.include states to comment out the separate scaLAPACK statements so that the intel MKL version is used. This is what I have done. This leads to hundreds of undefined references (see the file nohup.out for the complete list) such as the following. Any advice as to what to change to avoid this problem? Thanks!

Code: Select all

ld: scala.o: in function `scala_mp_init_scala_desc_':
scala.f90:(.text+0x1799): undefined reference to `blacs_gridexit_'
ld: scala.f90:(.text+0x1826): undefined reference to `blacs_gridinfo_'
ld: scala.f90:(.text+0x184a): undefined reference to `numroc_'
ld: scala.f90:(.text+0x187c): undefined reference to `numroc_'
ld: scala.f90:(.text+0x18c0): undefined reference to `descinit_'
ld: scala.f90:(.text+0x1b54): undefined reference to `numroc_'
ld: scala.f90:(.text+0x1b73): undefined reference to `numroc_'
ld: scala.f90:(.text+0x1bb4): undefined reference to `iceil_'
ld: scala.o: in function `scala_mp_procmap_':
scala.f90:(.text+0x1e68): undefined reference to `blacs_gridinit_'
ld: scala.f90:(.text+0x1ea2): undefined reference to `blacs_gridinfo_'
ld: scala.f90:(.text+0x1eb3): undefined reference to `blacs_pnum_'
ld: scala.f90:(.text+0x25ca): undefined reference to `blacs_gridexit_'
ld: scala.f90:(.text+0x25ee): undefined reference to `blacs_gridmap_'
ld: scala.o: in function `scala_mp_ppotrf_trtri_':

Code: Select all

# Intel MKL for FFTW, BLAS, LAPACK, and scaLAPACK
# (Note: for Intel Parallel Studio's MKL use -mkl instead of -qmkl)
FCL        += -qmkl
MKLROOT    ?= /path/to/your/mkl/installation
INCS        =-I$(MKLROOT)/include/fftw

# Use a separate scaLAPACK installation (optional but recommended in combination with OpenMPI)
# Comment out the two lines below if you want to use scaLAPACK from MKL instead
#SCALAPACK_ROOT ?= /path/to/your/scalapack/installation
#LLIBS      += -L${SCALAPACK_ROOT}/lib -lscalapack
You do not have the required permissions to view the files attached to this post.
Last edited by manuel_engel1 on Mon Feb 17, 2025 12:47 pm, edited 1 time in total.
Reason: Change quotes to code blocks, because otherwise the error messages are unreadable

manuel_engel1
Global Moderator
Global Moderator
Posts: 207
Joined: Mon May 08, 2023 4:08 pm

Re: using mkl scalapack option gives errors

#2 Post by manuel_engel1 » Tue Feb 18, 2025 11:26 am

Hello again :)

I suggest that you take a look at the arch/makefile.include.oneapi makefile.include. This one should be a better baseline or maybe even work out of the box for your scenario. You will see that there is a line

Code: Select all

LLIBS      += -L$(MKLROOT)/lib/intel64 -lmkl_scalapack_lp64 -lmkl_blacs_intelmpi_lp64

which is missing in your current makefile.include. Let me know how it goes.

Manuel Engel
VASP developer


User avatar
paulfons
Jr. Member
Jr. Member
Posts: 99
Joined: Sun Nov 04, 2012 2:40 am
License Nr.: 5-1405
Location: Yokohama, Japan
Contact:

Problems solved!

#3 Post by paulfons » Wed Feb 19, 2025 5:10 am

Thank you Manuel. Vasp is compiled and has passed the internal tests. Thank you for your help (and sorry about copying the wrong makefile.include!)

Best wishes,
Paul


manuel_engel1
Global Moderator
Global Moderator
Posts: 207
Joined: Mon May 08, 2023 4:08 pm

Re: using mkl scalapack option gives errors

#4 Post by manuel_engel1 » Wed Feb 19, 2025 10:19 am

No worries :-) I'm happy that you got to compile VASP. Good luck with your calculations!

Manuel Engel
VASP developer


Locked