NAMD
|
#include <CudaComputeNonbonded.h>
Classes | |
struct | ComputeRecord |
struct | PatchRecord |
Public Member Functions | |
CudaComputeNonbonded (ComputeID c, int deviceID, CudaNonbondedTables &cudaNonbondedTables, bool doStreaming) | |
~CudaComputeNonbonded () | |
void | registerComputeSelf (ComputeID cid, PatchID pid) |
void | registerComputePair (ComputeID cid, PatchID *pid, int *trans) |
void | assignPatches (ComputeMgr *computeMgrIn) |
virtual void | initialize () |
virtual void | atomUpdate () |
virtual int | noWork () |
virtual void | doWork () |
void | launchWork () |
void | finishReductions () |
void | unregisterBoxesOnPe () |
void | assignPatchesOnPe () |
void | openBoxesOnPe () |
void | skipPatchesOnPe () |
void | finishPatchesOnPe () |
void | finishPatchOnPe (int i) |
void | finishPatches () |
void | messageEnqueueWork () |
virtual void | patchReady (PatchID, int doneMigration, int seq) |
virtual void | gbisP2PatchReady (PatchID, int seq) |
virtual void | gbisP3PatchReady (PatchID, int seq) |
void | reSortTileLists () |
void | updatePatchOrder (const std::vector< CudaLocalRecord > &data) |
std::vector< PatchRecord > & | getPatches () |
![]() | |
Compute (ComputeID) | |
int | type () |
virtual | ~Compute () |
void | setNumPatches (int n) |
int | getNumPatches () |
int | sequence (void) |
int | priority (void) |
int | getGBISPhase (void) |
![]() | |
ComputeNonbondedUtil () | |
~ComputeNonbondedUtil () | |
void | calcGBIS (nonbonded *params, GBISParamStruct *gbisParams) |
Definition at line 31 of file CudaComputeNonbonded.h.
CudaComputeNonbonded::CudaComputeNonbonded | ( | ComputeID | c, |
int | deviceID, | ||
CudaNonbondedTables & | cudaNonbondedTables, | ||
bool | doStreaming | ||
) |
Definition at line 41 of file CudaComputeNonbonded.C.
References cudaCheck, Compute::gbisPhase, NAMD_die(), Node::Object(), Node::simParameters, and simParams.
CudaComputeNonbonded::~CudaComputeNonbonded | ( | ) |
Definition at line 115 of file CudaComputeNonbonded.C.
References cudaCheck, and ComputeMgr::sendUnregisterBoxesOnPe().
void CudaComputeNonbonded::assignPatches | ( | ComputeMgr * | computeMgrIn | ) |
Definition at line 384 of file CudaComputeNonbonded.C.
References PatchMap::basePatchIDList(), deviceCUDA, findHomePatchPe(), findProxyPatchPes(), DeviceCUDA::getDeviceCount(), DeviceCUDA::getMasterPeForDeviceID(), Compute::getNumPatches(), DeviceCUDA::getNumPesSharingDevice(), DeviceCUDA::getPesSharingDevice(), ComputePmeCUDAMgr::isPmePe(), NAMD_bug(), PatchMap::Object(), ComputePmeCUDAMgr::Object(), PatchMap::ObjectOnPe(), ComputeMgr::sendAssignPatchesOnPe(), and Compute::setNumPatches().
Referenced by ComputeMgr::createComputes().
void CudaComputeNonbonded::assignPatchesOnPe | ( | ) |
Definition at line 322 of file CudaComputeNonbonded.C.
References ResizeArray< Elem >::add(), NAMD_bug(), PatchMap::node(), PatchMap::Object(), and ResizeArray< Elem >::size().
Referenced by ComputeMgr::recvAssignPatchesOnPe().
|
virtual |
Reimplemented from Compute.
Definition at line 686 of file CudaComputeNonbonded.C.
|
virtual |
Reimplemented from Compute.
Definition at line 1112 of file CudaComputeNonbonded.C.
References SimParameters::CUDASOAintegrate, Flags::doEnergy, Flags::doFullElectrostatics, Flags::doMinimize, Flags::doNonbonded, Flags::doVirial, Compute::gbisPhase, NAMD_bug(), Node::Object(), openBoxesOnPe(), CudaTileListKernel::prepareBuffers(), ComputeMgr::sendOpenBoxesOnPe(), Node::simParameters, and simParams.
void CudaComputeNonbonded::finishPatches | ( | ) |
Definition at line 1943 of file CudaComputeNonbonded.C.
References cudaCheck, SimParameters::CUDASOAintegrate, finishPatchesOnPe(), and ComputeMgr::sendFinishPatchesOnPe().
void CudaComputeNonbonded::finishPatchesOnPe | ( | ) |
Definition at line 1931 of file CudaComputeNonbonded.C.
Referenced by finishPatches(), and ComputeMgr::recvFinishPatchesOnPe().
void CudaComputeNonbonded::finishPatchOnPe | ( | int | i | ) |
Definition at line 1938 of file CudaComputeNonbonded.C.
Referenced by ComputeMgr::recvFinishPatchOnPe().
void CudaComputeNonbonded::finishReductions | ( | ) |
Definition at line 1629 of file CudaComputeNonbonded.C.
References ADD_TENSOR_OBJECT, cudaCheck, SimParameters::CUDASOAintegrate, VirialEnergy::energyElec, VirialEnergy::energyElec_s, VirialEnergy::energyElec_ti_1, VirialEnergy::energyElec_ti_2, VirialEnergy::energyGBIS, VirialEnergy::energySlow, VirialEnergy::energySlow_s, VirialEnergy::energySlow_ti_1, VirialEnergy::energySlow_ti_2, VirialEnergy::energyVdw, VirialEnergy::energyVdw_s, VirialEnergy::energyVdw_ti_1, VirialEnergy::energyVdw_ti_2, SimParameters::GBISOn, CudaTileListKernel::getNumExcluded(), SubmitReduction::item(), NodeReduction::item(), NAMD_bug(), REDUCTION_COMPUTE_CHECKSUM, REDUCTION_ELECT_ENERGY, REDUCTION_ELECT_ENERGY_F, REDUCTION_ELECT_ENERGY_SLOW, REDUCTION_ELECT_ENERGY_SLOW_F, REDUCTION_ELECT_ENERGY_SLOW_TI_1, REDUCTION_ELECT_ENERGY_SLOW_TI_2, REDUCTION_ELECT_ENERGY_TI_1, REDUCTION_ELECT_ENERGY_TI_2, REDUCTION_EXCLUSION_CHECKSUM_CUDA, REDUCTION_LJ_ENERGY, REDUCTION_LJ_ENERGY_F, REDUCTION_LJ_ENERGY_TI_1, REDUCTION_LJ_ENERGY_TI_2, SubmitReduction::submit(), VirialEnergy::virial, VirialEnergy::virialSlow, Tensor::xx, Tensor::xy, Tensor::xz, Tensor::yx, Tensor::yy, Tensor::yz, Tensor::zx, Tensor::zy, and Tensor::zz.
Referenced by ComputeMgr::recvFinishReductions().
|
virtual |
Reimplemented from Compute.
Definition at line 264 of file CudaComputeNonbonded.C.
References Compute::gbisP2PatchReady().
|
virtual |
Reimplemented from Compute.
Definition at line 270 of file CudaComputeNonbonded.C.
References Compute::gbisP3PatchReady().
|
static |
|
static |
Definition at line 2341 of file CudaComputeNonbonded.C.
References ComputeNonbondedUtil::c1, ComputeNonbondedUtil::cutoff, ComputeNonbondedUtil::cutoff2, CudaNBConstants::e_0, CudaNBConstants::e_0_slow, CudaNBConstants::e_1, CudaNBConstants::e_2, CudaNBConstants::ewald_0, CudaNBConstants::ewald_1, CudaNBConstants::ewald_2, CudaNBConstants::ewald_3_slow, ComputeNonbondedUtil::ewaldcof, CudaNBConstants::lj_0, CudaNBConstants::lj_1, CudaNBConstants::lj_2, CudaNBConstants::lj_3, CudaNBConstants::lj_4, CudaNBConstants::lj_5, ComputeNonbondedUtil::pi_ewaldcof, simParams, CudaNBConstants::slowScale, ComputeNonbondedUtil::switchOn, and ComputeNonbondedUtil::switchOn2.
|
inline |
Definition at line 304 of file CudaComputeNonbonded.h.
|
virtual |
Reimplemented from Compute.
Definition at line 629 of file CudaComputeNonbonded.C.
References ATOMIC_BINS, cudaCheck, deviceCUDA, DeviceCUDA::getDeviceIndex(), PatchMap::numPatches(), PatchMap::Object(), Node::Object(), ReductionMgr::Object(), Compute::priority(), PatchData::reduction, REDUCTIONS_BASIC, Node::simParameters, and ReductionMgr::willSubmit().
Referenced by ComputeMgr::createComputes().
void CudaComputeNonbonded::launchWork | ( | ) |
Definition at line 1176 of file CudaComputeNonbonded.C.
References CudaComputeNonbonded::PatchRecord::atomStart, ResizeArray< Elem >::begin(), cudaCheck, ComputeNonbondedUtil::cutoff, ResizeArray< Elem >::end(), Patch::flags, Compute::gbisPhase, CudaTileListKernel::getEmptyPatches(), CudaTileListKernel::getNumEmptyPatches(), CudaTileListKernel::getNumPatches(), Patch::getPatchID(), CudaComputeNonbondedKernel::getPatchReadyQueue(), PatchMap::homePatchList(), SubmitReduction::item(), NodeReduction::item(), NAMD_bug(), NAMD_EVENT_START, NAMD_EVENT_STOP, CudaComputeNonbonded::PatchRecord::numAtoms, PatchMap::Object(), Node::Object(), HomePatchElem::patch, CudaComputeNonbondedKernel::reduceVirialEnergy(), REDUCTION_PAIRLIST_WARNINGS, reSortTileLists(), Flags::savePairlists, Node::simParameters, simParams, Flags::step, and Flags::usePairlists.
Referenced by openBoxesOnPe(), and ComputeMgr::recvLaunchWork().
void CudaComputeNonbonded::messageEnqueueWork | ( | ) |
Definition at line 1025 of file CudaComputeNonbonded.C.
References WorkDistrib::messageEnqueueWork(), and NAMD_bug().
Referenced by ComputeMgr::recvMessageEnqueueWork().
|
virtual |
Reimplemented from Compute.
Definition at line 1077 of file CudaComputeNonbonded.C.
References ComputeMgr::sendMessageEnqueueWork().
void CudaComputeNonbonded::openBoxesOnPe | ( | ) |
Definition at line 1031 of file CudaComputeNonbonded.C.
References SimParameters::CUDASOAintegrate, Compute::getNumPatches(), launchWork(), NAMD_bug(), NAMD_EVENT_START, NAMD_EVENT_STOP, Node::Object(), and ComputeMgr::sendLaunchWork().
Referenced by doWork(), and ComputeMgr::recvOpenBoxesOnPe().
|
virtual |
Reimplemented from Compute.
Definition at line 247 of file CudaComputeNonbonded.C.
References SimParameters::CUDASOAintegrate, NAMD_bug(), Compute::patchReady(), and SimParameters::useDeviceMigration.
Definition at line 185 of file CudaComputeNonbonded.C.
References PatchMap::center(), Compute::cid, PatchMap::Object(), Vector::x, Vector::y, and Vector::z.
void CudaComputeNonbonded::reSortTileLists | ( | ) |
Definition at line 1998 of file CudaComputeNonbonded.C.
References cudaCheck, Node::Object(), CudaTileListKernel::reSortTileLists(), Node::simParameters, and simParams.
Referenced by launchWork().
void CudaComputeNonbonded::skipPatchesOnPe | ( | ) |
Definition at line 798 of file CudaComputeNonbonded.C.
References Compute::getNumPatches(), NAMD_bug(), and ComputeMgr::sendFinishReductions().
Referenced by ComputeMgr::recvSkipPatchesOnPe().
void CudaComputeNonbonded::unregisterBoxesOnPe | ( | ) |
Definition at line 163 of file CudaComputeNonbonded.C.
References NAMD_bug().
Referenced by ComputeMgr::recvUnregisterBoxesOnPe().
void CudaComputeNonbonded::updatePatchOrder | ( | const std::vector< CudaLocalRecord > & | data | ) |
Definition at line 600 of file CudaComputeNonbonded.C.