etmc / tmLQCD

tmLQCD is a freely available software suite providing a set of tools to be used in lattice QCD simulations. This is mainly a HMC implementation (including PHMC and RHMC) for Wilson, Wilson Clover and Wilson twisted mass fermions and inverter for different versions of the Dirac operator. The code is fully parallelised and ships with optimisations for various modern architectures, such as commodity PC clusters and the Blue Gene family.
http://www.itkp.uni-bonn.de/~urbach/software.html
GNU General Public License v3.0
32 stars 47 forks source link

Quda work merge master #486

Closed kostrzewa closed 3 years ago

kostrzewa commented 3 years ago

Here's my attempt to synchronise master and quda_work. I've not tested compilation and hence also not done any regression tests. To be honest, I never wanted to touch this code again...

kostrzewa commented 3 years ago

It would be nice if someone could set up github actions to at least automatically test the build system...

sunpho84 commented 3 years ago

what do you mean? isn't travis cehcking the build?

kostrzewa commented 3 years ago

what do you mean? isn't travis cehcking the build?

that has been broken for ages.

kostrzewa commented 3 years ago

Anyway, this builds now on my machine but one has to be careful to create a new build directory (or appropriately empty the current one) because there is a change to the files generated in ${top_build_dir}/include.

kostrzewa commented 3 years ago

Doing the following:

CC=mpicc CXX=mpicxx F77=f77 \                                                                                                                                
CFLAGS="-mtune=znver2 -march=znver2 -O3 -mavx2 -mfma -fopenmp" \
LDFLAGS="-fopenmp" \
~/code/tmLQCD.merge_quda_work/configure \
  --enable-mpi \
  --with-mpidimension=4 \
  --disable-sse2 --disable-sse3 \
  --with-cudadir=/usr/local/cuda/lib64 \
  --with-qudadir=$(pwd)/../quda_develop/install_dir \
  --with-limedir=$(pwd)/../lime/install_dir \
  --with-lapack="-lblas -llapack"

in an empty build directory works for me, but maybe there is still some compiler dependence...

sunpho84 commented 3 years ago

Doing the following:

CC=mpicc CXX=mpicxx F77=f77 \                                                                                                                                
CFLAGS="-mtune=znver2 -march=znver2 -O3 -mavx2 -mfma -fopenmp" \
LDFLAGS="-fopenmp" \
~/code/tmLQCD.merge_quda_work/configure \
  --enable-mpi \
  --with-mpidimension=4 \
  --disable-sse2 --disable-sse3 \
  --with-cudadir=/usr/local/cuda/lib64 \
  --with-qudadir=$(pwd)/../quda_develop/install_dir \
  --with-limedir=$(pwd)/../lime/install_dir \
  --with-lapack="-lblas -llapack"

in an empty build directory works for me, but maybe there is still some compiler dependence...

yes actually it almost does, now I get

../../io/utils_write_first_message.c: In function ‘write_first_messages’:
../../io/utils_write_first_message.c:27:115: error: ‘TMLQCD_PACKAGE_VERSION’ undeclared (first use in this function); did you mean ‘LIME_PACKAGE_VERSION’?
   27 |   snprintf(message, 1024, "This is the %s code for twisted mass Wilson QCD\n\nVersion %s, commit %s\n",executable,TMLQCD_PACKAGE_VERSION,git_hash);
      |                                                                                                                   ^~~~~~~~~~~~~~~~~~~~~~
      |                                                                                                                   LIME_PACKAGE_VERSION
../../io/utils_write_first_message.c:27:115: note: each undeclared identifier is reported only once for each function it appears in
kostrzewa commented 3 years ago

yes actually it almost does, now I get

delete the file include/tmlqcd_config.h in your build dir, it's a left-over from a previous build which is not deleted by the build system (since now a different file is auto-generated)

sunpho84 commented 3 years ago

ok I see, a make distclean did the trick

kostrzewa commented 3 years ago

Had to make one more modif, moving the non-generated file into the include/ directory in the source dir. This is in order to be able to grab the settings when using tmLQCD as a library in an external program as in that case, one doesn't want to have to specify the source directory itself as an include dir (as there might be include files with the same names between the client app and tmLQCD). In the end, both tmlqcd_config.h and tmlqcd_config_internal.h should of course be installed.

I've checked this now linked against my cvc_depgraph extension of CVC and the changes merged in from master don't seem to break the QUDA behaviour.

sunpho84 commented 3 years ago

what do you mean? isn't travis cehcking the build?

that has been broken for ages.

? travis is checking my fork and he seems to be rather happy...

https://travis-ci.com/github/sunpho84/tmLQCD/builds/222046903