Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0?

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

Moderators: Global Moderator, Moderator

Post Reply
Message
Author
hszhao.cn@gmail.com
Jr. Member
Jr. Member
Posts: 99
Joined: Tue Oct 13, 2020 11:32 pm

Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0?

#1 Post by hszhao.cn@gmail.com » Wed Feb 16, 2022 12:07 pm

It's well known that Intel MKL is very powerful and complicated. As far as I am concerned, there are still many problems that I can't understand from time to time, for example, here's one of the questions that bothers me about compiling VASP 6.3.0: Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0? Though Intel has given some description and explanation on the topic on its website here, I still don't quite understand how to choose between them when compiling VASP. Any hints will be highly appreciated.

See here for more detailed on all the available options while using Intel MKL.

Regards,
HZ

ferenc_karsai
Global Moderator
Global Moderator
Posts: 422
Joined: Mon Nov 04, 2019 12:44 pm

Re: Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0?

#2 Post by ferenc_karsai » Thu Feb 17, 2022 8:05 am

Use LP64. Large integers are a problem when a single dimension of an array on a single core gets larger than 2^31. Usually in scaLAPACK the arrays are distributed so this can only happen in special cases, where one has very large matrices. We have never encountered this in standard DFT methods, but for example we encountered this in BSE. To make large integers available it's not enough to compile with ILP64 but also the calling routines need to be changed so that they use large integers. We are working on it to make this available everywhere in the code.

For including LP64 do it as in the example makefile.includes from the "arch" directory:
MKLROOT ?= /path/to/your/mkl/installation
LLIBS += -L$(MKLROOT)/lib/intel64 -lmkl_scalapack_lp64 -lmkl_blacs_intelmpi_lp64

hszhao.cn@gmail.com
Jr. Member
Jr. Member
Posts: 99
Joined: Tue Oct 13, 2020 11:32 pm

Re: Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0?

#3 Post by hszhao.cn@gmail.com » Fri Feb 18, 2022 4:22 am

ferenc_karsai wrote: Thu Feb 17, 2022 8:05 am Use LP64. Large integers are a problem when a single dimension of an array on a single core gets larger than 2^31. Usually in scaLAPACK the arrays are distributed so this can only happen in special cases, where one has very large matrices. We have never encountered this in standard DFT methods, but for example we encountered this in BSE. To make large integers available it's not enough to compile with ILP64 but also the calling routines need to be changed so that they use large integers. We are working on it to make this available everywhere in the code.
Thank you for your explanation and thank the VASP developers for their hard work.
ferenc_karsai wrote: Thu Feb 17, 2022 8:05 am For including LP64 do it as in the example makefile.includes from the "arch" directory:
MKLROOT ?= /path/to/your/mkl/installation
LLIBS += -L$(MKLROOT)/lib/intel64 -lmkl_scalapack_lp64 -lmkl_blacs_intelmpi_lp64
If the Environment Modules tools, such as lmod or traditional modules have been used to manage the user environment in HPC situation, MKLROOT will always be set, so there is needless to set the corresponding line above.

ferenc_karsai
Global Moderator
Global Moderator
Posts: 422
Joined: Mon Nov 04, 2019 12:44 pm

Re: Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0?

#4 Post by ferenc_karsai » Fri Feb 18, 2022 6:53 am

Yes, but depends on your system and build. Unfortunately we can only give templates for the malefile.includes and the users have to adapt.

Post Reply