In addition to providing recent versions of CP2K on HECToR (see
http://www.hector.ac.uk/support/documentation/software/cp2k/ for details) containing the improvements described in this report, below are some general points of advice for users wishing to achieve best performance from CP2K on HECToR. Of course, nothing substitutes for careful benchmarking on a shortened version of the problem you are trying to solve (for example performing only a single MD step, or a reduced number of SCF cycles).
Firstly, try to choose a number of MPI processes that is a square, to maximise the performance of DBCSR (see section 3.2. Secondly, use whole nodes (multiples of 32 cores on HECToR Phase 3). Thirdly, if possible choose a number of processes that is a power of two. Following these guidelines, better performance might be obtained on 64, 256, 1024 MPI processes, depending on problem size.
As discussed in section 3.1.1, using libsmm can give significant performance improvements over regular BLAS DGEMM for simulations involving small block sizes (elements with low atomic number, small basis sets). The centrally-installed CP2K package is linked with libsmm, or if you wish to build your own version from source, pass -D__HAS_smm_dnn to the compiler, and link the library in /usr/local/packages/cp2k/2.3.15/libs/libsmm/
For large problem sizes in particular, or on large numbers of cores, using perhaps 2 or 4 OpenMP threads per MPI process may give better performance than pure MPI. OpenMP may also be of use for problems requiring large amounts of memory, where otherwise nodes would have to be underpopulated. An OpenMP-capable binary of CP2K (cp2k.psmp) is provided in the CP2K package on HECToR. If using OpenMP, consider experimenting with the communication thread settings as described in section 3.1.3, which may provide further speed improvements. In some cases (particularly on small numbers of cores, where the compute to communication ratio is high, it may be beneficial to switch the comm thread off).
Finally, for any issues regarding CP2K on HECToR please contact the HECToR helpdesk email@example.com.