Improve Nbnxm kernel unit tests
Summary
The new Nbnxm kernel unit tests are a great improvement but can be improved further before we extend to cover e.g. GPU cases.
Use cases
Impact on users is only indirect, in that developers will have an easier time handling these tests and extending coverage.
Impact
This will reduce code, simplify the structure and use more standard GoogleTest approaches.
Detailed description
Specific improvements
-
Three kernel flavors run in the same test (for forces-only, energies, energy groups), which saves some processing by reusing data structures, duplicates some code, requires extra custom handling to do the right thing for each flavor (which requires access into internal output data structures that is otherwise unnecessary), and risks falling out of step with how the main code works. It would be better to test only a single flavor per test, skipping the inapplicable reference test data, which will run slower (more disk access) but have less code and code that follows more natural paths. !4175 (merged) -
The standard GoogleTest
skip mechanism should be used to skip kernel flavors that don't make sense for the build configuration or reference-data generation. !4250 (merged) -
Dynamic registration can likely be avoided once the standard skipping mechanism is used. !3921 (merged) -
We should have some small or artfully constructed systems whose results are amenable to human inspection for correctness. -
Optimizations for clusters without VDW parameters should be explicitly tested as well as the current implicit approach.
General improvements
-
Preprocessing is used to require that the reference data can only be generated from a double precision build. We should extend the test infrastructure to make this available generally and avoid the preprocessor. !4254 (merged) -
We now have several kinds of tests that want to test different flavors on the same reference data (e.g. at least also PME tests). We should extract, document, and re-use some common machinery for this. !4256
Edited by Mark Abraham