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
Should I use the ILP64 interface or LP64 interface of Intel MKL while compiling VASP 6.3.0?
Moderators: Global Moderator, Moderator
-
- Full Member
- Posts: 189
- Joined: Tue Oct 13, 2020 11:32 pm
-
- Global Moderator
- Posts: 460
- 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?
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
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
-
- Full Member
- Posts: 189
- 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?
Thank you for your explanation and thank the VASP developers for their hard work.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.
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 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
-
- Global Moderator
- Posts: 460
- 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?
Yes, but depends on your system and build. Unfortunately we can only give templates for the malefile.includes and the users have to adapt.