Do not call mixed CPU+GPU PME mode "Hybrid"
authorAleksei Iupinov <a.yupinov@gmail.com>
Thu, 23 Nov 2017 14:02:22 +0000 (15:02 +0100)
committerAleksei Iupinov <a.yupinov@gmail.com>
Fri, 24 Nov 2017 17:53:07 +0000 (18:53 +0100)
Change-Id: I2739d366f819c1d50bed10f40e887ba571fa56e4

src/gromacs/ewald/pme-only.cpp
src/gromacs/ewald/pme.cpp
src/gromacs/ewald/pme.h
src/gromacs/mdlib/sim_util.cpp
src/programs/mdrun/runner.cpp

index 6f8dfa57acafe491115f54964ef9fe5c78ba4d59..91a7b686534e831a8b6508fe4305e79db076e2dc 100644 (file)
@@ -551,7 +551,7 @@ int gmx_pmeonly(struct gmx_pme_t *pme,
 
     auto       pme_pp       = gmx_pme_pp_init(cr);
     //TODO the variable below should be queried from the task assignment info
-    const bool useGpuForPme = (runMode == PmeRunMode::GPU) || (runMode == PmeRunMode::Hybrid);
+    const bool useGpuForPme = (runMode == PmeRunMode::GPU) || (runMode == PmeRunMode::Mixed);
     if (useGpuForPme)
     {
         changePinningPolicy(&pme_pp->chargeA, gmx::PinningPolicy::CanBePinned);
index c90254b0a34c7e16d0f66a692706eb0b7434cccc..b440e7e79d367b8598765d72efa2c65b4ed8ccdb 100644 (file)
@@ -816,7 +816,7 @@ gmx_pme_t *gmx_pme_init(const t_commrec     *cr,
                           pme->overlap[0].s2g1[pme->nodeid_major]-pme->overlap[0].s2g0[pme->nodeid_major+1],
                           pme->overlap[1].s2g1[pme->nodeid_minor]-pme->overlap[1].s2g0[pme->nodeid_minor+1]);
             /* This routine will allocate the grid data to fit the FFTs */
-            const auto allocateRealGridForGpu = (pme->runMode == PmeRunMode::Hybrid) ? gmx::PinningPolicy::CanBePinned : gmx::PinningPolicy::CannotBePinned;
+            const auto allocateRealGridForGpu = (pme->runMode == PmeRunMode::Mixed) ? gmx::PinningPolicy::CanBePinned : gmx::PinningPolicy::CannotBePinned;
             gmx_parallel_3dfft_init(&pme->pfft_setup[i], ndata,
                                     &pme->fftgrid[i], &pme->cfftgrid[i],
                                     pme->mpi_comm_d,
index 6452b9d091ccd3cf6c0b8783dcc25bbaf7b6ee65..b1dad4b9ba76143a1c78eec3120cc3c75640de1b 100644 (file)
@@ -84,7 +84,7 @@ enum PmeRunMode
     None,    //!< No PME task is done
     CPU,     //!< Whole PME computation is done on CPU
     GPU,     //!< Whole PME computation is done on GPU
-    Hybrid,  //!< Mixed mode: only spread and gather run on GPU; FFT and solving are done on CPU.
+    Mixed,   //!< Mixed mode: only spread and gather run on GPU; FFT and solving are done on CPU.
 };
 
 //! PME gathering output forces treatment
index 186b09017ab4500774f776be7f3a7b47cdecc8e8..240a152bf457b7150d67e5459bb2d46fe36344b0 100644 (file)
@@ -888,7 +888,7 @@ static void do_force_cutsVERLET(FILE *fplog, t_commrec *cr,
     const auto pmeRunMode = fr->pmedata ? pme_run_mode(fr->pmedata) : PmeRunMode::CPU;
     // TODO slim this conditional down - inputrec and duty checks should mean the same in proper code!
     const bool useGpuPme  = EEL_PME(fr->ic->eeltype) && thisRankHasDuty(cr, DUTY_PME) &&
-        ((pmeRunMode == PmeRunMode::GPU) || (pmeRunMode == PmeRunMode::Hybrid));
+        ((pmeRunMode == PmeRunMode::GPU) || (pmeRunMode == PmeRunMode::Mixed));
 
     /* At a search step we need to start the first balancing region
      * somewhere early inside the step after communication during domain
index 487eb3a5a0267d84f1d4453531b2ce661a637d02..58059f5c4c51a738e550130adaa9626a3edc8bcb 100644 (file)
@@ -656,7 +656,7 @@ int Mdrunner::mdrunner()
         pmeRunMode   = (useGpuForPme ? PmeRunMode::GPU : PmeRunMode::CPU);
         if ((pmeRunMode == PmeRunMode::GPU) && (pmeFftTarget == TaskTarget::Cpu))
         {
-            pmeRunMode = PmeRunMode::Hybrid;
+            pmeRunMode = PmeRunMode::Mixed;
         }
     }
     GMX_CATCH_ALL_AND_EXIT_WITH_FATAL_ERROR;
@@ -1104,7 +1104,7 @@ int Mdrunner::mdrunner()
          * mdAtoms is not filled with atom data,
          * as this can not be done now with domain decomposition.
          */
-        const bool useGpuForPme = (pmeRunMode == PmeRunMode::GPU) || (pmeRunMode == PmeRunMode::Hybrid);
+        const bool useGpuForPme = (pmeRunMode == PmeRunMode::GPU) || (pmeRunMode == PmeRunMode::Mixed);
         mdAtoms = makeMDAtoms(fplog, *mtop, *inputrec, useGpuForPme && thisRankHasDuty(cr, DUTY_PME));
         if (globalState)
         {