Gromacs
2024.3
|
#include "gmxpre.h"
#include "dlb.h"
#include "gromacs/domdec/domdec_struct.h"
#include "gromacs/gmxlib/nrnb.h"
#include "gromacs/utility/gmxassert.h"
#include "domdec_internal.h"
#include "utility.h"
This file implements functions to interact with the dynamic load balancing machinery.
Functions | |
float | dd_pme_f_ratio (const gmx_domdec_t *dd) |
Return the PME/PP force load ratio, or -1 if nothing was measured. More... | |
void | set_dlb_limits (gmx_domdec_t *dd) |
Sets the cell size limits for DD to suit dynamic load balancing. | |
void | dd_dlb_set_should_check_whether_to_turn_dlb_on (gmx_domdec_t *dd, gmx_bool bValue) |
Sets whether we should later check the load imbalance data, so that we can trigger dynamic load balancing if enough imbalance has arisen. More... | |
gmx_bool | dd_dlb_get_should_check_whether_to_turn_dlb_on (gmx_domdec_t *dd) |
Returns if we should check whether there has been enough load imbalance to trigger dynamic load balancing. More... | |
gmx_bool | dd_dlb_is_on (const gmx_domdec_t *dd) |
Return if we are currently using dynamic load balancing. | |
gmx_bool | dd_dlb_is_locked (const gmx_domdec_t *dd) |
Return if the DLB lock is set. | |
void | dd_dlb_lock (gmx_domdec_t *dd) |
Set a lock such that with DLB=auto DLB cannot get turned on. | |
void | dd_dlb_unlock (gmx_domdec_t *dd) |
Clear a lock such that with DLB=auto DLB may get turned on later. | |
gmx_bool dd_dlb_get_should_check_whether_to_turn_dlb_on | ( | gmx_domdec_t * | dd | ) |
Returns if we should check whether there has been enough load imbalance to trigger dynamic load balancing.
We need to check whether we check because it might be always off.
void dd_dlb_set_should_check_whether_to_turn_dlb_on | ( | gmx_domdec_t * | dd, |
bool | bValue | ||
) |
Sets whether we should later check the load imbalance data, so that we can trigger dynamic load balancing if enough imbalance has arisen.
Used after PME load balancing unlocks DLB, so that the check whether DLB will be useful can happen immediately.
float dd_pme_f_ratio | ( | const gmx_domdec_t * | dd | ) |
Return the PME/PP force load ratio, or -1 if nothing was measured.
Should only be called on the DD main node.