Merge branch release-2020 into master
authorPaul Bauer <paul.bauer.q@gmail.com>
Wed, 4 Mar 2020 07:05:31 +0000 (08:05 +0100)
committerPaul Bauer <paul.bauer.q@gmail.com>
Wed, 4 Mar 2020 07:07:03 +0000 (08:07 +0100)
Resolved Conflicts:
.gitlab-ci.yml
admin/builds/gromacs.py
cmake/gmxVersionInfo.cmake
src/gromacs/ewald/pme.cpp
src/gromacs/gmxana/gmx_disre.cpp
src/gromacs/gpu_utils/cudautils.cu
src/gromacs/gpu_utils/gpu_utils.cu
src/gromacs/hardware/gpu_hw_info.h
src/gromacs/listed_forces/orires.cpp
src/gromacs/mdlib/forcerec.cpp
src/gromacs/mdlib/forcerec.h
src/gromacs/mdlib/md_support.cpp
src/gromacs/mdlib/md_support.h
src/gromacs/mdlib/mdoutf.cpp
src/gromacs/mdlib/mdoutf.h
src/gromacs/mdlib/sim_util.cpp
src/gromacs/mdlib/vsite.cpp
src/gromacs/mdlib/vsite.h
src/gromacs/mdrun/minimize.cpp
src/gromacs/modularsimulator/forceelement.cpp
src/gromacs/modularsimulator/shellfcelement.cpp
src/gromacs/nbnxm/kernels_reference/kernel_ref.h
src/programs/mdrun/tests/CMakeLists.txt

Change-Id: Ic95c6b35c8a7b7bd0b9c3fa0833136d32bb74242

45 files changed:
1  2 
.gitlab-ci.yml
admin/builds/gromacs.py
admin/ci-templates/.build-template.yml
cmake/gmxCPackUtilities.cmake
cmake/gmxVersionInfo.cmake
docs/CMakeLists.txt
docs/release-notes/index.rst
docs/user-guide/mdp-options.rst
docs/user-guide/mdrun-performance.rst
src/gromacs/domdec/domdec_topology.cpp
src/gromacs/ewald/pme.cpp
src/gromacs/ewald/pme_gpu_internal.cpp
src/gromacs/fileio/checkpoint.cpp
src/gromacs/gmxana/gmx_disre.cpp
src/gromacs/gmxpreprocess/grompp.cpp
src/gromacs/gmxpreprocess/readir.cpp
src/gromacs/gpu_utils/cudautils.cu
src/gromacs/gpu_utils/gpu_utils.cu
src/gromacs/hardware/gpu_hw_info.h
src/gromacs/listed_forces/orires.cpp
src/gromacs/mdlib/dispersioncorrection.cpp
src/gromacs/mdlib/forcerec.cpp
src/gromacs/mdlib/forcerec.h
src/gromacs/mdlib/md_support.cpp
src/gromacs/mdlib/md_support.h
src/gromacs/mdlib/mdoutf.cpp
src/gromacs/mdlib/mdoutf.h
src/gromacs/mdlib/sim_util.cpp
src/gromacs/mdlib/vsite.cpp
src/gromacs/mdlib/vsite.h
src/gromacs/mdrun/md.cpp
src/gromacs/mdrun/mimic.cpp
src/gromacs/mdrun/minimize.cpp
src/gromacs/mdrun/rerun.cpp
src/gromacs/mdrun/runner.cpp
src/gromacs/modularsimulator/constraintelement.cpp
src/gromacs/modularsimulator/forceelement.cpp
src/gromacs/modularsimulator/modularsimulator.cpp
src/gromacs/modularsimulator/modularsimulator.h
src/gromacs/modularsimulator/parrinellorahmanbarostat.cpp
src/gromacs/modularsimulator/shellfcelement.cpp
src/gromacs/nbnxm/kernels_reference/kernel_ref.h
src/gromacs/nbnxm/nbnxm_geometry.h
src/gromacs/taskassignment/decidegpuusage.cpp
src/programs/mdrun/tests/CMakeLists.txt

diff --cc .gitlab-ci.yml
index 91b693e1537cf79b97ea771ccddcd5a96c312a7a,fd58a9b844634a5d2d77f23a242d401ebcc0411d..ae0f97fc4611acb6b4b89c3be11e054af7aaffb1
@@@ -76,94 -76,104 +76,104 @@@ stages
  
  # Templates for configuration stage
  .configure-gcc:
 -    extends:
 -      - .configure-extends-template
 -      - .gcc-before-script-template
 -      - .build-gcc-template
 +  extends:
 +    - .configure-extends-template
 +    - .gcc-before-script-template
 +    - .build-gcc-template
  
  .configure-gcc-release:
 -    extends:
 -      - .configure-release-extends-template
 -      - .gcc-before-script-template
 -      - .build-gcc-template
 +  extends:
 +    - .configure-release-extends-template
 +    - .gcc-before-script-template
 +    - .build-gcc-template
  
+ .configure-gcc-cuda:
+     extends:
+       - .configure-gcc
+       - .cuda-template
  .configure-clang:
 -    extends:
 -      - .configure-extends-template
 -      - .clang-before-script-template
 -      - .build-clang-template
 +  extends:
 +    - .configure-extends-template
 +    - .clang-before-script-template
 +    - .build-clang-template
  
  .configure-clang-release:
 -    extends:
 -      - .configure-release-extends-template
 -      - .clang-before-script-template
 -      - .build-clang-template
 +  extends:
 +    - .configure-release-extends-template
 +    - .clang-before-script-template
 +    - .build-clang-template
  
  .configure-docs:
 -    extends:
 -      - .configure-extends-template
 -      - .configure-docs-template
 -      - .documentation-before-script-template
 +  extends:
 +    - .configure-extends-template
 +    - .configure-docs-template
 +    - .documentation-before-script-template
  
  .configure-docs-release:
 -    extends:
 -      - .configure-extends-template
 -      - .configure-docs-release-template
 -      - .documentation-before-script-template
 +  extends:
 +    - .configure-extends-template
 +    - .configure-docs-release-template
 +    - .documentation-before-script-template
  
  # Templates for build stage
  .build-archive:
 -    extends:
 -      - .build-extends-template
 -      - .documentation-before-script-template
 -      - .build-docs-binary-template
 -      - .archive-build-template
 +  extends:
 +    - .build-extends-template
 +    - .documentation-before-script-template
 +    - .build-docs-binary-template
 +    - .archive-build-template
  
  .build-gcc:
 -    extends:
 -      - .build-extends-template
 -      - .gcc-before-script-template
 -      - .build-gcc-template
 +  extends:
 +    - .build-extends-template
 +    - .gcc-before-script-template
 +    - .build-gcc-template
  
  .build-clang:
 -    extends:
 -      - .build-extends-template
 -      - .clang-before-script-template
 -      - .build-clang-template
 +  extends:
 +    - .build-extends-template
 +    - .clang-before-script-template
 +    - .build-clang-template
  
  .build-docs-binary:
 -    extends:
 -      - .build-extends-template
 -      - .build-cache-template
 -      - .build-docs-binary-template
 -      - .documentation-before-script-template
 +  extends:
 +    - .build-extends-template
 +    - .build-cache-template
 +    - .build-docs-binary-template
 +    - .documentation-before-script-template
  
  .build-docs-webpage:
 -    extends:
 -      - .binary-build-template
 -      - .variables-template
 -      - .tags-template
 -      - .no-cache-template
 -      - .build-docs-webpage-template
 -      - .documentation-before-script-template
 +  extends:
 +    - .binary-build-template
 +    - .variables-template
 +    - .tags-template
 +    - .no-cache-template
 +    - .build-docs-webpage-template
 +    - .documentation-before-script-template
  
- .build-cuda-gcc:
-   extends:
-     - .build-gcc
-     - .build-cuda-template
+ .build-gcc-cuda:
+     extends:
+       - .build-gcc
+       - .cuda-template
  
  # Templates for test stage
  .test-gcc:
 -    extends:
 -      - .test-extends-template
 -      - .gcc-before-script-template
 -      - .test-gcc-template
 +  extends:
 +    - .test-extends-template
 +    - .gcc-before-script-template
 +    - .test-gcc-template
  
+ .test-gcc-cuda:
+     extends:
+       - .test-gcc
+       - .cuda-template
  .test-clang:
 -    extends:
 -      - .test-extends-template
 -      - .clang-before-script-template
 -      - .test-clang-template
 +  extends:
 +    - .test-extends-template
 +    - .clang-before-script-template
 +    - .test-clang-template
  
  # Special job to package regressiontest files and have them available for testing
  # Runs during pre-build
@@@ -196,112 -206,123 +206,123 @@@ simple-build
  
  # Jobs running in first pre-build stage
  configure-gcc-7:
 -    extends:
 -      - .configure-gcc
 -      - .gcc7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-gcc
 +    - .gcc7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 7
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 7
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  configure-gcc-7-gmxapi:
 -    extends:
 -      - .configure-gcc
 -      - .configure-gmxapi-template
 -      - .gcc7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-gcc
 +    - .configure-gmxapi-template
 +    - .gcc7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 7
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 7
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  configure-gcc-7-double:
 -    extends:
 -      - .configure-gcc
 -      - .gcc7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-gcc
 +    - .gcc7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 7
 +    CMAKE_PRECISION_OPTIONS: -DGMX_DOUBLE=ON
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 7
 -        CMAKE_PRECISION_OPTIONS: -DGMX_DOUBLE=ON
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  configure-gcc-8:
 -    extends:
 -      - .configure-gcc
 -      - .gcc8-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-gcc
 +    - .gcc8-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 8
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 8
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
+ configure-gcc-8-cuda-10.2:
+     extends:
+       - .configure-gcc-cuda
+       - .gcc-8-cuda-10.2-template
+     needs:
+       - job: simple-build
+         artifacts: false
+     except:
+       variables:
+         - $GROMACS_RELEASE
  configure-gcc-7-simd-sse41:
 -    extends:
 -      - .configure-gcc
 -      - .gcc7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-gcc
 +    - .gcc7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 7
 +    CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=SSE4.1"
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 7
 -        CMAKE_SIMD_OPTIONS: "-DGMX_SIMD=SSE4.1"
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  configure-clang-7:
 -    extends:
 -      - .configure-clang
 -      - .clang7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-clang
 +    - .clang7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 7
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 7
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  configure-clang-7-gmxapi:
 -    extends:
 -      - .configure-clang
 -      - .configure-gmxapi-template
 -      - .clang7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-clang
 +    - .configure-gmxapi-template
 +    - .clang7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 7
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 7
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  configure-clang-8:
 -    extends:
 -      - .configure-clang
 -      - .clang8-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false
 +  extends:
 +    - .configure-clang
 +    - .clang8-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +  variables:
 +    COMPILER_MAJOR_VERSION: 8
 +  except:
      variables:
 -        COMPILER_MAJOR_VERSION: 8
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +      - $GROMACS_RELEASE
  
  # For version of clang before 7, we need to always provide the full version
  # Use something like this instead in the download script:
@@@ -416,41 -437,265 +437,260 @@@ build-gcc-7
  
  
  build-gcc-7-gmxapi:
 -    extends:
 -      - .build-gcc
 -      - .gmxapi-extra-installs
 -      - .gcc7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false 
 -      - job: configure-gcc-7-gmxapi
 -        artifacts: true
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +  extends:
 +    - .build-gcc
 +    - .gmxapi-extra-installs
 +    - .gcc7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +    - job: configure-gcc-7-gmxapi
 +      artifacts: true
 +  except:
 +    variables:
 +      - $GROMACS_RELEASE
  
  build-gcc-7-double:
 -    extends:
 -      - .build-gcc
 -      - .gcc7-template
 -    needs:
 -      - job: simple-build
 -        artifacts: false 
 -      - job: configure-gcc-7-double
 -        artifacts: true
 -    except:
 -      variables:
 -        - $GROMACS_RELEASE
 +  extends:
 +    - .build-gcc
 +    - .gcc7-template
 +  needs:
 +    - job: simple-build
 +      artifacts: false
 +    - job: configure-gcc-7-double
 +      artifacts: true
 +  except:
 +    variables:
 +      - $GROMACS_RELEASE
  
  build-gcc-8:
+     extends:
+       - .build-gcc
+       - .gcc8-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: configure-gcc-8
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ build-gcc-8-cuda-10.2:
+     extends:
+       - .build-gcc-cuda
+       - .gcc-8-cuda-10.2-template
+     needs:
+       - job: simple-build
+         artifacts: false
+       - job: configure-gcc-8-cuda-10.2
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ build-gcc-7-simd-sse41:
+     extends:
+       - .build-gcc
+       - .gcc7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: configure-gcc-7-simd-sse41
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ build-clang-7:
+     extends:
+       - .build-clang
+       - .clang7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: configure-clang-7
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ build-clang-7-gmxapi:
+     extends:
+       - .build-clang
+       - .gmxapi-extra-installs
+       - .clang7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: configure-clang-7-gmxapi
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ build-clang-8:
+     extends:
+       - .build-clang
+       - .clang8-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: configure-clang-8
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ build-clang-6:
+     extends:
+       - .build-clang
+       - .clang6-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: configure-clang-6
+         artifacts: true
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ # Jobs running during test stage
+ test-gcc-7:
+     extends:
+       - .test-gcc
+       - .gcc7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-gcc-7
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-gcc-7-gmxapi:
+     extends:
+       - .test-gcc
+       - .gmxapi-extra-installs
+       - .gcc7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-gcc-7-gmxapi
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-gcc-7-double:
+     extends:
+       - .test-gcc
+       - .gcc7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-gcc-7-double
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-gcc-8:
+     extends:
+       - .test-gcc
+       - .gcc8-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-gcc-8
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-gcc-8-cuda-10.2:
+     variables:
+       KUBERNETES_EXTENDED_RESOURCE_NAME: "nvidia.com/gpu"
+       KUBERNETES_EXTENDED_RESOURCE_LIMIT: 1
+     extends:
+       - .test-gcc-cuda
+       - .gcc-8-cuda-10.2-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-gcc-8-cuda-10.2
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-gcc-7-simd-sse41:
+     extends:
+       - .test-gcc
+       - .gcc7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-gcc-7-simd-sse41
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-clang-7:
+     extends:
+       - .test-clang
+       - .clang7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-clang-7
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-clang-7-gmxapi:
+     extends:
+       - .test-clang
+       - .gmxapi-extra-installs
+       - .clang7-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-clang-7-gmxapi
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-clang-8:
+     extends:
+       - .test-clang
+       - .clang8-template
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-clang-8
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ test-clang-6:
+     extends:
+       - .test-clang
+       - .clang6-template       
+     needs:
+       - job: simple-build
+         artifacts: false 
+       - job: build-clang-6
+     except:
+       variables:
+         - $GROMACS_RELEASE
+ # Jobs running in source checking stage
+ build-clang-tidy:
    extends:
 -    - .build-clang
 -    - .clang7-template
 -  stage: source-check
 +    - .build-gcc
 +    - .gcc8-template
    needs:
      - job: simple-build
 -      artifacts: false 
 -    - job: configure-clang-tidy
 +      artifacts: false
 +    - job: configure-gcc-8
        artifacts: true
 -  variables:
 -      BUILD_DIR: build-clang-tidy
 -      COMPILER_MAJOR_VERSION: 7
 -      EXTRA_INSTALLS: clang-tidy-$COMPILER_MAJOR_VERSION
    except:
      variables:
        - $GROMACS_RELEASE
index d78c29c13ede1b383ec59ab695a828014847aeca,cb9d78e3ba2a075d4cec5a6b9dbd512d681ca4ea..7dce328844b31afb28e15b8a6067a034f95f8b19
@@@ -1,8 -1,7 +1,8 @@@
  #
  # This file is part of the GROMACS molecular simulation package.
  #
- # Copyright (c) 2015,2016,2017,2018,2019,2020, by the GROMACS development team.
 -# Copyright (c) 2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++# Copyright (c) 2015,2016,2017,2018,2019,2020, The GROMACS development team.
 +# Copyright (c) 2020, by the GROMACS development team, led by
  # Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
  # and including many others, as listed in the AUTHORS file in the
  # top-level source directory and at http://www.gromacs.org.
Simple merge
Simple merge
index d900ca80b4d0355415d646e23b648c68b059a586,a671ea5dcd5db176c52e8160b8f0fdbdecedcd5b..932ba838fb1531184e6fd9c2c8a98a5191f49c04
@@@ -364,16 -361,8 +364,17 @@@ if (SPHINX_FOUND
          how-to/visualize.rst
          install-guide/index.rst
          release-notes/index.rst
 +        release-notes/2021/major/highlights.rst
 +        release-notes/2021/major/features.rst
 +        release-notes/2021/major/performance.rst
 +        release-notes/2021/major/tools.rst
 +        release-notes/2021/major/bugs-fixed.rst
 +        release-notes/2021/major/removed-functionality.rst
 +        release-notes/2021/major/deprecated-functionality.rst
 +        release-notes/2021/major/portability.rst
 +        release-notes/2021/major/miscellaneous.rst
          release-notes/2020/2020.1.rst
+         release-notes/2020/2020.2.rst
          release-notes/2020/major/highlights.rst
          release-notes/2020/major/features.rst
          release-notes/2020/major/performance.rst
Simple merge
Simple merge
Simple merge
Simple merge
index 78bf617dbe8843f6ec3340ef66cf9412d90ef89f,e2c3059774913e524b85a85625a47245bfd991d8..255f273fde9101bfb890eed131281d61ce8b06f2
@@@ -1013,27 -1034,9 +1012,28 @@@ void pme_gpu_reinit_atoms(PmeGpu* pmeGp
          pme_gpu_realloc_spline_data(pmeGpu);
          pme_gpu_realloc_grid_indices(pmeGpu);
      }
+     pme_gpu_select_best_performing_pme_spreadgather_kernels(pmeGpu);
  }
  
 +/*! \internal \brief
 + * Returns raw timing event from the corresponding GpuRegionTimer (if timings are enabled).
 + * In CUDA result can be nullptr stub, per GpuRegionTimer implementation.
 + *
 + * \param[in] pmeGpu         The PME GPU data structure.
 + * \param[in] PMEStageId     The PME GPU stage gtPME_ index from the enum in src/gromacs/timing/gpu_timing.h
 + */
 +static CommandEvent* pme_gpu_fetch_timing_event(const PmeGpu* pmeGpu, size_t PMEStageId)
 +{
 +    CommandEvent* timingEvent = nullptr;
 +    if (pme_gpu_timings_enabled(pmeGpu))
 +    {
 +        GMX_ASSERT(PMEStageId < pmeGpu->archSpecific->timingEvents.size(),
 +                   "Wrong PME GPU timing event index");
 +        timingEvent = pmeGpu->archSpecific->timingEvents[PMEStageId].fetchNextEvent();
 +    }
 +    return timingEvent;
 +}
 +
  void pme_gpu_3dfft(const PmeGpu* pmeGpu, gmx_fft_direction dir, int grid_index)
  {
      int timerId = (dir == GMX_FFT_REAL_TO_COMPLEX) ? gtPME_FFT_R2C : gtPME_FFT_C2R;
Simple merge
index 70fa6e5480fa979530e8d7bbca79c3b3ae6c2a38,608677f69fdc572f32c9b7009f0c0c681f5cb47c..046573194a9db863758e58dddac12a85bb5fd3f1
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
Simple merge
Simple merge
index 8574d7ef8dc270929fd4d63075d5e73b190281eb,209b00a95a51515ebe79c5633404055bb34ad70d..1442bf47c2298462be116a3ec7ab2ef0d4de138a
@@@ -1,8 -1,7 +1,8 @@@
  /*
   * This file is part of the GROMACS molecular simulation package.
   *
-  * Copyright (c) 2012,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2012,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2012,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
Simple merge
index 98f87760cddef0df4aaeb8f48b078abe68671ffa,a8b3144ee5b32f88c52a24a30d4e8eda8f7fb569..8952ca4f8747333d47bc8d55b3f578bed47d9d71
@@@ -1,8 -1,7 +1,8 @@@
  /*
   * This file is part of the GROMACS molecular simulation package.
   *
-  * Copyright (c) 2012,2013,2014,2015,2017 by the GROMACS development team.
 - * Copyright (c) 2012,2013,2014,2015,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2012,2013,2014,2015,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
index 63f09ba0cf3f109e13970734932771f034a465e7,2867c07a15118d36784a3d64cccb30acbb2e41b2..d9c58c9574192dce6ed8d54845c64ced32da2fc1
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
Simple merge
index cba9875e48eb40954c2c8597e077266ad094b0a5,39e5093af99f95a7a3c58e4b880f5bbd931591ba..c7f38cb5f5b800a11bce29de1ef13dfe5c5b58bc
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013-2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
@@@ -114,8 -120,24 +114,19 @@@ void init_forcerec(FILE
                     const char*                      tabfn,
                     const char*                      tabpfn,
                     gmx::ArrayRef<const std::string> tabbfnm,
 -                   const gmx_hw_info_t&             hardwareInfo,
 -                   const gmx_device_info_t*         deviceInfo,
 -                   bool                             useGpuForBonded,
 -                   bool                             pmeOnlyRankUsesGpu,
 -                   real                             print_force,
 -                   gmx_wallcycle*                   wcycle);
 +                   real                             print_force);
  
+ /*! \brief Check whether molecules are ever distributed over PBC boundaries
+  *
+  * Note: This covers only the non-DD case. For DD runs, domdec.h offers an
+  *       equivalent dd_bonded_molpbc(...) function.
+  *
+  * \param[in]  ir                 Inputrec structure
+  * \param[in]  mtop               Molecular topology
+  * \param[in]  mdlog              File for printing
+  */
+ bool areMoleculesDistributedOverPbc(const t_inputrec& ir, const gmx_mtop_t& mtop, const gmx::MDLogger& mdlog);
  /*! \brief Divide exclusions over threads
   *
   * Set the exclusion load for the local exclusions and possibly threads
index 9eb763a25d1a47b826353e1950c422999c3cd49e,8f06530c9d29edd44385741fb779df9dc38683fc..33056bc855cf580e759f91c09bd65d88b06ab5c3
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
index e13fa1f4838da0caa0415f1c194545b1785f78a3,2918ed87f7747d82eef7070bac411baf9c10b560..333cde82ec8c90f7c280afb0fe830ad874fadbc5
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
index 3f3a426fb83cad4e6826797290373e4bcd0e2a2d,950587952db12a0995a755f129ffa4c232149c46..dac8b7754d04f354fe4c1763a19bd334966e1f5f
@@@ -1,8 -1,7 +1,8 @@@
  /*
   * This file is part of the GROMACS molecular simulation package.
   *
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
@@@ -296,12 -308,18 +309,18 @@@ void mdoutf_write_to_trajectory_files(F
          {
              fflush_tng(of->tng);
              fflush_tng(of->tng_low_prec);
+             /* Write the checkpoint file.
+              * When simulations share the state, an MPI barrier is applied before
+              * renaming old and new checkpoint files to minimize the risk of
+              * checkpoint files getting out of sync.
+              */
              ivec one_ivec = { 1, 1, 1 };
              write_checkpoint(of->fn_cpt, of->bKeepAndNumCPT, fplog, cr,
 -                             DOMAINDECOMP(cr) ? cr->dd->nc : one_ivec,
 +                             DOMAINDECOMP(cr) ? cr->dd->numCells : one_ivec,
                               DOMAINDECOMP(cr) ? cr->dd->nnodes : cr->nnodes, of->eIntegrator,
                               of->simulation_part, of->bExpanded, of->elamstats, step, t,
-                              state_global, observablesHistory, *(of->mdModulesNotifier));
+                              state_global, observablesHistory, *(of->mdModulesNotifier),
+                              of->simulationsShareState, of->mpiCommMasters);
          }
  
          if (mdof_flags & (MDOF_X | MDOF_V | MDOF_F))
index 4add522f7971f3d3d572589cb2d9bc9d6ffbafb9,1eca3f9a354a0a99683b912fd9d53fd4f672ad7e..a6f9371ce6eee68897c41e6fee0786434adee6f7
@@@ -1,8 -1,7 +1,8 @@@
  /*
   * This file is part of the GROMACS molecular simulation package.
   *
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
Simple merge
index 5d8d19ef21e83b579974f3e7b476570e7ef255ee,59427c294485e1d1e4a7b31cae31c0a5bb97f30a..74c82f64598d9a298624094441c119e2a6965bc5
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
index 8069b6250c7ea87d17f57d2fc9885db171793203,a3ea432bf1349d2fa34f22b9fd1d4585d3201f33..65287fcb14827696d493f92c5b7c7b9c7a3be7f3
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
Simple merge
Simple merge
index 6b36ce823b9a9569afab95865207ea84058cbb3b,d90af4f9d791d2685ae70a3a9d81245655c8be70..3fc65f392f966cfa4737385490152413ebe547bc
@@@ -3,8 -3,7 +3,8 @@@
   *
   * Copyright (c) 1991-2000, University of Groningen, The Netherlands.
   * Copyright (c) 2001-2004, The GROMACS development team.
-  * Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 - * Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
Simple merge
Simple merge
index 4a0b7fe545b6c456b0cfa0a1881919bb7d039a7f,8e96e6068b19e7ddc336c044c31a509c7b31ffcc..fcd03cd8d0868215746a5436932aebff6ab4df18
@@@ -125,14 -126,12 +126,15 @@@ void ConstraintsElement<variable>::appl
  {
      tensor vir_con;
  
 -    rvec *x, *xprime, *min_proj, *v;
 +    ArrayRefWithPadding<RVec> x;
 +    ArrayRefWithPadding<RVec> xprime;
 +    ArrayRef<RVec>            min_proj;
 +    ArrayRefWithPadding<RVec> v;
  
-     // disabled functionality
-     real  lambda    = 0;
-     real* dvdlambda = nullptr;
+     const real lambdaBonded = freeEnergyPerturbationElement_
+                                       ? freeEnergyPerturbationElement_->constLambdaView()[efptBONDED]
+                                       : 0;
+     real dvdlambda = 0;
  
      switch (variable)
      {
index c3bf1bb5525b899e079a7474fa0884615b24a447,0b28b49ed08e027d5364504807d20e8f4a51fabd..36f304b3dcf6a79fb7ece4ffa356af9f532135c2
@@@ -47,7 -47,8 +47,9 @@@
  #include "gromacs/mdlib/force.h"
  #include "gromacs/mdlib/force_flags.h"
  #include "gromacs/mdlib/mdatoms.h"
+ #include "gromacs/mdtypes/inputrec.h"
 +#include "gromacs/mdtypes/mdatom.h"
+ #include "gromacs/pbcutil/pbc.h"
  
  #include "energyelement.h"
  #include "freeenergyperturbationelement.h"
index 380a1c287d3021f173144f438b3c968d565c1c31,8ccc6ab35f266589cf721c5bf97caa0d554c7a84..8eca620e4c21459e222cc645e63c383d16fa3958
@@@ -51,7 -51,7 +51,8 @@@
  #include "gromacs/mdlib/mdatoms.h"
  #include "gromacs/mdrun/shellfc.h"
  #include "gromacs/mdtypes/inputrec.h"
 +#include "gromacs/mdtypes/mdatom.h"
+ #include "gromacs/pbcutil/pbc.h"
  #include "gromacs/topology/atoms.h"
  #include "gromacs/topology/mtop_util.h"
  
index e98d2deba6b85311a7b10fbbbd8b9608b2c756ad,85080ab6267d1132ecc035d011e279e19ccbce2c..242536c99f7784930b795552a39db7ceef2e188a
@@@ -1,8 -1,7 +1,8 @@@
  /*
   * This file is part of the GROMACS molecular simulation package.
   *
-  * Copyright (c) 2012,2013,2014,2015,2017 by the GROMACS development team.
 - * Copyright (c) 2012,2013,2014,2015,2017,2018,2019,2020, by the GROMACS development team, led by
++ * Copyright (c) 2012,2013,2014,2015,2017 The GROMACS development team.
 + * Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
   * Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
   * and including many others, as listed in the AUTHORS file in the
   * top-level source directory and at http://www.gromacs.org.
index debc49b17e3e2b1315c0d4a6fec536e6e9eae78d,2b724323719ea72132a0623b70304125cb9af268..3362a410db3c7fd50ec1a92e6ff6985f9a505d60
@@@ -90,10 -82,10 +90,10 @@@ static constexpr gmx::EnumerationArray<
  #else
        0, 0,
  #endif
-       c_nbnxnGpuClusterSize, c_nbnxnGpuClusterSize }
+       c_nbnxnGpuClusterSize, c_nbnxnGpuClusterSize / 2 }
  };
  
 -/* Returns whether the pair-list corresponding to nb_kernel_type is simple */
 +/*! \brief Returns whether the pair-list corresponding to nb_kernel_type is simple */
  static inline bool kernelTypeUsesSimplePairlist(const KernelType kernelType)
  {
      return (kernelType == KernelType::Cpu4x4_PlainC || kernelType == KernelType::Cpu4xN_Simd_4xN
index 315b30e24223d677ee73f000b4071e4471b6c612,f2e7e2d8bb3227f1bf3a7e89d89acb0c9a1d3ccf..24af506d980463cd454b414bf83cd17ea49fbb41
@@@ -1,8 -1,7 +1,8 @@@
  #
  # This file is part of the GROMACS molecular simulation package.
  #
- # Copyright (c) 2013,2014,2015,2016,2017 by the GROMACS development team.
 -# Copyright (c) 2013,2014,2015,2016,2017,2018,2019,2020, by the GROMACS development team, led by
++# Copyright (c) 2013,2014,2015,2016,2017 The GROMACS development team.
 +# Copyright (c) 2018,2019,2020, by the GROMACS development team, led by
  # Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl,
  # and including many others, as listed in the AUTHORS file in the
  # top-level source directory and at http://www.gromacs.org.