Arcane  4.1.12.0
Developer documentation
Loading...
Searching...
No Matches
ICriteriaLoadBalanceMng.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2026 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
4// See the top-level COPYRIGHT file for details.
5// SPDX-License-Identifier: Apache-2.0
6//-----------------------------------------------------------------------------
7/*---------------------------------------------------------------------------*/
8/* ICriteriaLoadBalanceMng.h (C) 2000-2024 */
9/* */
10/* Interface for a load balance criteria manager for meshes. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_CORE_ICRITERIALOADBALANCEMNG_H
13#define ARCANE_CORE_ICRITERIALOADBALANCEMNG_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
18#include "arcane/core/VariableTypes.h"
19
20/*---------------------------------------------------------------------------*/
21/*---------------------------------------------------------------------------*/
22
23namespace Arcane
24{
25
26/*---------------------------------------------------------------------------*/
27/*---------------------------------------------------------------------------*/
28
34{
35 public:
36
37 virtual ~ICriteriaLoadBalanceMng() = default;
38
39 public:
40
46 virtual void addCriterion(VariableCellInt32& count) = 0;
47
53 virtual void addCriterion(VariableCellReal& count) = 0;
54
55 // TODO Understand how PartitionerMemoryInfo works
62 virtual void addMass(VariableCellInt32& count, const String& entity) = 0;
63
70 virtual void addCommCost(VariableFaceInt32& count, const String& entity) = 0;
71
75 virtual void reset() = 0;
76
83 virtual void setMassAsCriterion(bool active) = 0;
84
91 virtual void setNbCellsAsCriterion(bool active) = 0;
92
99 virtual void setCellCommContrib(bool active) = 0;
100
105 virtual void setComputeComm(bool active) = 0;
106
112 virtual Integer nbCriteria() = 0;
113};
114
115/*---------------------------------------------------------------------------*/
116/*---------------------------------------------------------------------------*/
117
118} // End namespace Arcane
119
120/*---------------------------------------------------------------------------*/
121/*---------------------------------------------------------------------------*/
122
123#endif
Declarations of Arcane's general types.
Class interface allowing criteria to be added to adjust the load balance.
virtual void addCriterion(VariableCellReal &count)=0
Method allowing a criterion to be added for each cell.
virtual void addMass(VariableCellInt32 &count, const String &entity)=0
Method allowing a criterion to be added for each cell.
virtual void setNbCellsAsCriterion(bool active)=0
Method allowing to specify if the number of cells in a subdomain must be a criterion for load balance...
virtual ~ICriteriaLoadBalanceMng()=default
Frees resources.
virtual Integer nbCriteria()=0
Method allowing to retrieve the number of criteria already registered.
virtual void addCriterion(VariableCellInt32 &count)=0
Method allowing a criterion to be added for each cell.
virtual void setComputeComm(bool active)=0
virtual void addCommCost(VariableFaceInt32 &count, const String &entity)=0
Method allowing a criterion to be added for each face.
virtual void setMassAsCriterion(bool active)=0
Method allowing to specify if the data mass of each cell is a criterion for load balance.
virtual void setCellCommContrib(bool active)=0
Method allowing to specify if the mass of communications between cells must be a criterion for load b...
virtual void reset()=0
Method allowing the criteria already added to be cleared.
MeshVariableScalarRefT< Cell, Real > VariableCellReal
Real type quantity at cell center.
MeshVariableScalarRefT< Cell, Int32 > VariableCellInt32
Quantity at the cell center of 32-bit integer type.
MeshVariableScalarRefT< Face, Int32 > VariableFaceInt32
Quantity at the face of 32-bit integer type.
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --
Int32 Integer
Type representing an integer.