Compiling NWChem 6.3 on Cray XC30 (ARCHER) with Intel


Clicked A Few Times
Hi,

Just a note about compiling NWChem on the UK national supercomputing service ARCHER using Intel compilers in case anyone else tries to do the same. As a first attempt I compiled a basic MPI-TS build with the following settings:

export NWCHEM_TOP=...
export NWCHEM_TARGET=LINUX64
export USE_MPI=y
export USE_MPIF=y
export USE_MPIF4=y
export LIBMPI=" "
export ARMCI_NETWORK=MPI-TS
export USE_64TO32=y
make FC=ftn nwchem_config NWCHEM_MODULES=all &> make_config.log
make 64_to_32 &> make_64to32.log
make FC=ftn &> make.log

This seemed to compile OK but in certain circumstances it gives incorrect results, in particular for the force (as printed in force.dat) on the point charge of the following input:


title "nwchem" 
memory 100 mb
print medium
start nwchem
geometry print units bohr nocenter noautoz
symmetry c1 tol 0.0
zn 0.00000000000000 0.00000000000000 0.00000000000000
end
bq units au
force force.dat
0.00000000000000 3.77945332702064 0.00000000000000 2.0000000000
end
basis print
zn library 3-21g
end
charge 0
set scf:converged false
task scf gradient


I traced the error back to the file src/property/hnd_elfcon.F where the standard Intel compiler optimisations cause the loop in the subroutine multi_reduce to give an incorrect result. I tried switching the i and j loops but the errors persisted (albeit with different numbers). However the errors can be avoided by moving hnd_elfcon.o from OBJ_OPTIMIZE to OBJ in src/property/GNUmakefile, as a result of the lower optimisation level used.

I am not sure whether this is an XC30-specific issue or simply a compiler problem. My Intel build on my local machine is not affected, but I am using a different compiler version (13.0.1 vs 14.0.1 on Archer).

NB: the standard NWChem module on ARCHER is compiled with GNU compilers and so is not affected by this problem.

Tom

Forum Vet
Tom
Thanks for the detailed bug report
Edo

Forum Vet
Tom
I was able to reproduce your failure with ifort 14.0.1.
I have tried ifort 14.0.3, too; ifort 14.0.3 generates correct code, instead.

You can avoid the Intel 14.0.1 failure by adding the following line just before the call to mat_reduce

!DEC$ NOINLINE


Cheers, Edo


PS. Here is a more complete diff ouput


$ svn diff hnd_elfcon.F
Index: hnd_elfcon.F
===================================================================
--- hnd_elfcon.F	(revision 25615)
+++ hnd_elfcon.F	(working copy)
@@ -90,7 +90,7 @@
                call int_1eelec(basis,ishell,basis,jshell,maxscr,
      &                         dbl_mb(k_scr),nint,dbl_mb(k_buf),
      &                         nder,points,npt)
-c
+!DEC$ NOINLINE
                call multi_reduce(dbl_mb(k_buf),dbl_mb(k_dens),
      &                           elfval,idim,jdim,npt*(max(nder*3,1)))
             end if  ! mod parallel loop

Clicked A Few Times
Hi Edo,

OK, thanks for clearing that up. I'll let the Archer people know they should upgrade!

Cheers

Tom


Forum >> NWChem's corner >> Compiling NWChem