Hardware detection clean-up and pre/post-processing
commit6d99d7eaa33b77a703aabbe3bce070cf1a261787
authorErik Lindahl <erik@kth.se>
Thu, 7 Jul 2016 14:01:13 +0000 (7 16:01 +0200)
committerMark Abraham <mark.j.abraham@gmail.com>
Sat, 9 Jul 2016 19:22:52 +0000 (9 21:22 +0200)
tree8e76227aaff74b3d9489b99bd8c50b6b8b363029
parent07d120957728dd271752128113b58b45f6b8e194
Hardware detection clean-up and pre/post-processing

This change cleans up the various tests and hacks we have
had in different places to remove a number of false warnings
and errors. It also unifies all this processing to two
small routines that are called just before/after the
hardware is detected, so the user can choose whether it
should be done or not in other places.

- Rather than trying to guess when we should or shouldn't
  override the number of cores online, the preprocessing
  uses a piece of code that allows sleeping cores to come
  online automatically by running a small C++11 thread loop before
  doing the hardware topology detection. This way we can
  remove all ARM-specific paths. To avoid wasting a second
  on systems where SMT is disabled, we avoid calling it on x86.
- All SMT warnings are handled in the post-processing call,
  but only as notes in the log file to avoid writing
  warnings on stderr.
- The check for OpenMP thread mismatch has been removed
  since it caused incorrect warnings by comparing the number
  or threads configured for each OpenMP process with the
  total number of cores in the entire system. We will have
  to rewrite this later as a test in the MPI/OpenMP
  parallelization setup instead.

By sticking with the hwloc/sysconf-online detection, we should
now also handle all special cases where cores have been taken
offline manually in a correct way without using hardware-specific
paths.

Change-Id: I37edb3eada3f4c8c0906c641c7041cc0270985e8
cmake/gmxTestCXX11.cmake
docs/doxygen/includesorter.py
docs/user-guide/mdrun-performance.rst
src/gromacs/hardware/detecthardware.cpp
src/gromacs/hardware/detecthardware.h
src/gromacs/hardware/hardwaretopology.cpp
src/gromacs/hardware/hardwaretopology.h
src/gromacs/hardware/tests/hardwaretopology.cpp
src/programs/mdrun/runner.cpp