<div dir="ltr"><div>Hello  Stanislav,</div><div>I would suggest starting with a minimal CP2K installation, i.e. without any major library, lust MKL (with FFTW) and IntelMPI.</div><div>An arch file would be:</div><div><br></div><div>CC       = cc</div><div>CPP      = </div><div>FC       = mpiifort </div><div>LD       = mpiifort </div><div>AR       = ar -r</div><div><br></div><div>CPPFLAGS =<br></div><div>DFLAGS   = -D__MKL -D__FFTW3 -D__parallel \</div><div><span style="white-space:pre">    </span>   -D__SCALAPACK</div><div>CFLAGS   = $(DFLAGS) </div><div>MKLROOT = <path to MKL></div><div>FCFLAGS  = $(DFLAGS) -O2 -g -traceback -fpp -free \</div><div>           -I$(MKLROOT)/include -I$(MKLROOT)/include/fftw</div><div>FCFLAGS2  = $(DFLAGS) -O0 -g -traceback -fpp -free \</div><div>           -I$(MKLROOT)/include -I$(MKLROOT)/include/fftw</div><div>LDFLAGS  = $(FCFLAGS) -static-intel </div><div>LDFLAGS_C = $(FCFLAGS) -static-intel -nofor_main</div><div>LIBS     = $(MKLROOT)/lib/intel64/libmkl_scalapack_lp64.a \</div><div><span style="white-space:pre">     </span> -Wl,--start-group  $(MKLROOT)/lib/intel64/libmkl_intel_lp64.a \</div><div><span style="white-space:pre">     </span> $(MKLROOT)/lib/intel64/libmkl_sequential.a \</div><div><span style="white-space:pre"> </span> $(MKLROOT)/lib/intel64/libmkl_core.a \</div><div><span style="white-space:pre">       </span> $(MKLROOT)/lib/intel64/libmkl_blacs_intelmpi_lp64.a -Wl,--end-group \</div><div><span style="white-space:pre">        </span> -lpthread -lm</div><div><br></div><div># Required due to memory leak that occurs if high optimisations are used</div><div>mp2_optimize_ri_basis.o: mp2_optimize_ri_basis.F</div><div><span style="white-space:pre"> </span>$(FC) -c $(FCFLAGS2) $<</div><div><br></div><div>Concerning the compiler, please take a look at this page</div><div><br></div><div>https://www.cp2k.org/dev:compiler_support<br></div><div><br></div><div>Intel 17.0.2 is not tested by CP2K people, so I'm not sure if it works. It would be better to use 17.0.4 or 18.0.3. They are both well tested...</div><div>The best would be to run the CP2K regression test.</div><div><br></div><div>Assuming that everything works fine, then I would move to include other libraries (libxsmm, ELPA, LIBXC, Libint).</div><div><br></div><div>Cheers,</div><div><br></div><div>Alfio</div><div><br></div><div><br></div><div><br></div><br><br>Il giorno domenica 16 settembre 2018 01:33:30 UTC+2, Stanislav Šimko ha scritto:<blockquote class="gmail_quote" style="margin: 0;margin-left: 0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;"><div dir="ltr">Well, it's unfortunately getting a lot messier. I got cp2k compiled on 2 machines in the end, but I get bad results. On both machines, I use intel 17.0.2 compilers. Results on both machines are different (and presumably wrong) from each other. I also compared results of the input file to results obtained by an older versions (4.1 compiled with gcc on one machine, 3.0 compiled with some intel compilers on the second machine; these two installations gave same results). All energies except the self energy is different:<div>"coorect"</div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div><div>  Overlap energy of the core charge distribution:               0.00000310201993</div></div><div><div>  Self energy of the core charge distribution:              -1007.31897988265303</div></div><div><div>  Core Hamiltonian energy:                                    295.26625363987614</div></div><div><div>  Hartree energy:                                             418.52562360415197</div></div><div><div>  Exchange-correlation energy:                               -101.48179826891138</div></div><div><div><br></div></div><div><div>  Total energy:                                              -395.00889780551631</div></div><div><div><br></div></div><div><div>  outer SCF iter =    1 RMS gradient =   0.00E+00 energy =       -395.0088978055</div></div><div><div>  outer SCF loop converged in   1 iterations or   15 steps</div></div><div><div><br></div></div><div><div><br></div></div><div><div> ENERGY| Total FORCE_EVAL ( QS ) energy (a.u.):             -395.008897805517336</div></div></blockquote><div><br></div><div>wrong output files are attached. I'm now trying to find out how to test LIBINT, LIBXC, LIBXSMM and ELPA. Haven't had much luck yet.</div><div><br></div><div>Thank you for any suggestions.</div></div></blockquote></div>