Gromacs
2020.4
|
#include "gmxpre.h"
#include "kernel_common.h"
#include "gromacs/pbcutil/ishift.h"
#include "gromacs/utility/gmxassert.h"
Implements utility functions used by all nbnxm CPU kernels.
Functions | |
static void | clearBufferAll (gmx::ArrayRef< real > buffer) |
Clears all elements of buffer. | |
template<int numComponentsPerElement> | |
static void | clearBufferFlagged (const nbnxn_atomdata_t &nbat, int outputIndex, gmx::ArrayRef< real > buffer) |
Clears elements of size and stride numComponentsPerElement . More... | |
void | clearForceBuffer (nbnxn_atomdata_t *nbat, int outputIndex) |
Clears the force buffer. More... | |
void | clear_fshift (real *fshift) |
Clears the shift forces. | |
void | reduce_energies_over_lists (const nbnxn_atomdata_t *nbat, int nlist, real *Vvdw, real *Vc) |
Reduces the collected energy terms over the pair-lists/threads. | |
|
static |
Clears elements of size and stride numComponentsPerElement
.
Only elements with flags in nbat
set for index outputIndex
are cleared.
void clearForceBuffer | ( | nbnxn_atomdata_t * | nbat, |
int | outputIndex | ||
) |
Clears the force buffer.
Either the whole buffer is cleared or only the parts used by thread/task outputIndex
when nbat->bUseBufferFlags is set.
[in,out] | nbat | The Nbnxm atom data |
[in] | outputIndex | The index of the output object to clear |