Peano
Loading...
Searching...
No Matches
Statistics.h
Go to the documentation of this file.
1// This file is part of the Peano project. For conditions of distribution and
2// use, please see the copyright notice at www.peano-framework.org
3#pragma once
4
5
6#include "tarch/logging/Log.h"
7
8
9#include "State.h"
10
11
12namespace toolbox {
13 namespace loadbalancing {
14 class Statistics;
15 }
16}
17
18
19
Log Device.
Definition Log.h:517
Statistics helper routine for load balancing.
Definition Statistics.h:39
int _localNumberOfSplits
Rank-local accumulator where I keep track of how often I did split since the last updateGlobalView().
Definition Statistics.h:117
int getGlobalNumberOfRanksWithEnabledLoadBalancing() const
static constexpr int MaxNumberOfStateUpdatesWithoutAnySplit
Saturation value of getNumberOfStateUpdatesWithoutAnySplit()
Definition Statistics.h:106
int _globalNumberOfSplits
Sum of all ranks' local number of splits at the last updateGlobalView()
Definition Statistics.h:127
bool _localLoadBalancingEnabled
Rank-local: Is the load balancing on this rank switched on.
Definition Statistics.h:111
static tarch::logging::Log _log
Definition Statistics.h:101
void updateGlobalView()
Update the global statistics view on all ranks.
void incLocalNumberOfSplits(int delta=1)
Rank-local: Bookmark that this rank has triggered a split.
int getNumberOfStateUpdatesWithoutAnySplit() const
Number of updateGlobalView() calls without any split on any rank.
int getLocalNumberOfSplits() const
Number of splits this rank has triggered since the last updateGlobalView()
void notifyOfStateChange(State state)
Rank-local: Memorise whether the load balancing on this rank is switched on.
State
State descriptor of load balancing.
Definition State.h:22