[Wien] Installation with MPI and GNU compilers

Fecher, Gerhard fecher at uni-mainz.de
Wed May 2 11:00:23 CEST 2018


I never checked that: does the  -DINTEL_VML switch correspond to the
VML library routines of MKL
or to the
SVML library routines of the compiler
this makes a difference, the svml routines are automatically invoked by the INTEL compiler if one uses -O2 optimization or higher.
(check also the usage of the switches -vec, -no-vec, -vec-report)

The VML routines of the MKL make only sense for appropriate sizes of the vectors, otherwise, they may even slow down the program (how much might also depend on threads etc.).

A note (for the INTEL Fortran):
I vaguely remember that the -DINTEL_VML switch did not bring any better performance, at that time one needed to give the -lsvml (with path to the compiler libs) explicitely.

Ciao
Gerhard

DEEP THOUGHT in D. Adams; Hitchhikers Guide to the Galaxy:
"I think the problem, to be quite honest with you,
is that you have never actually known what the question is."

====================================
Dr. Gerhard H. Fecher
Institut of Inorganic and Analytical Chemistry
Johannes Gutenberg - University
55099 Mainz
and
Max Planck Institute for Chemical Physics of Solids
01187 Dresden
________________________________________
Von: Wien [wien-bounces at zeus.theochem.tuwien.ac.at] im Auftrag von Pavel Ondračka [pavel.ondracka at email.cz]
Gesendet: Mittwoch, 2. Mai 2018 10:30
An: A Mailing list for WIEN2k users
Betreff: Re: [Wien] Installation with MPI and GNU compilers

Rui Costa píše v Po 30. 04. 2018 v 22:24 +0100:
> I have the VML libraries, i.e., the libmkl_vml_* files are in
> $MKLROOT/lib/intel_64, but when I tried compiling with -DINTEL_VML it
> gave me the error "Fatal Error: Can't open module file ‘ifcore.mod’
> for reading at (1): No such file or directory", and this file only
> comes with the compilers.

Yeah, I have not realized that the INTEL_VML ifdef also guards the use
of ifcore stuff, IMO this could be improved by using two defines, one
for the actual VML calls (which would be defined when MKL is present)
and one for the ifcore library calls (which would be defined only when
also the ifort is detected).

BTW as a quick hack to make the lapw1 fast, just change all the
#if defined (INTEL_VML)
lines in SRC_lapw1/hamilt.F
to
#if defined (INTEL_VML_HAMILT)
and add the -DINTEL_VML_HAMILT flag
this should be all that is needed to use the VML in lapw1

> To use the libmvec library I would have to change a few lines of code
> in the mkl libraries and that is beyond my computer skills.

Actually no changes to the MKL are required. The least obtrusive way as
described in https://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.
at/msg16159.html only consist of copying single c file to SRC_lapw1
compiling it by hand and than rerunning make to link lapw1 with the new
object file (i.e. no changes to any Wien2k files are needed). However
the VML way is easier when you already have the MKL set up.

Best regards,
Pavel

> Best regards,
> Rui Costa.
>
> On 30 April 2018 at 20:57, Pavel Ondračka <pavel.ondracka at email.cz>
> wrote:
> > ---------- Původní e-mail ----------
> > Od: Rui Costa <ruicosta.r15 at gmail.com>
> > Komu: A Mailing list for WIEN2k users <wien at zeus.theochem.tuwien.ac
> > .at>
> > Datum: 30. 4. 2018 19:39:44
> > Předmět: Re: [Wien] Installation with MPI and GNU compilers
> >
> > > I was able to install wien2k with gfortran+MKL. Apparently the
> > > MKL libraries are free [https://software.intel.com/en-us/performa
> > > nce-libraries] but not the compilers.
> > >
> > > While doing the benchmark tests we noticed that during the Hamilt
> > > there was a huge difference between this and an ifort+MKL
> > > compilation, and as Pavel said, this comes from the VML
> > > functions. This is not the case during DIAG because while the
> > > DIAG belongs to MKL, Hamilt is from wien2k. I then tried to
> > > compile with these VML functions but I couldn't because I need an
> > > ifcore.mod file that comes with intel compilers I think, at least
> > > it is not in the free MKL version.
> > >
> > > Do you have any recommendation about the compilation options that
> > > could better optimize wien2k?
> >
> > Dear Rui,
> >
> > so to make this clear, your MKL comes without the VML, or are you
> > just not able to use/link them? I do not understand the part with
> > the ifcore.mod much, however the VML paths are guarded with some
> > ifdef magic, try adding  -DINTEL_VML to your flags (FOPT, FPOPT)
> > and see if it helps.
> >
> > The second option is to use the libmvec library (provided you have
> > fairly new glibc) but it is unsupported by the Wien2k team and
> > probably not tested by many people except me. If you cannot get the
> > VML working, look for older emails discussing libmvec or contact me
> > privately and I can give you some pointers.
> >
> > No idea about the -it problem though.
> >
> > Best regards
> > Pavel
> >
> > _______________________________________________
> > Wien mailing list
> > Wien at zeus.theochem.tuwien.ac.at
> > http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
> > SEARCH the MAILING-LIST at:  http://www.mail-archive.com/wien@zeus.
> > theochem.tuwien.ac.at/index.html
> >
>
> _______________________________________________
> Wien mailing list
> Wien at zeus.theochem.tuwien.ac.at
> http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
> SEARCH the MAILING-LIST at:  http://www.mail-archive.com/wien@zeus.th
> eochem.tuwien.ac.at/index.html
_______________________________________________
Wien mailing list
Wien at zeus.theochem.tuwien.ac.at
http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
SEARCH the MAILING-LIST at:  http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html


More information about the Wien mailing list