Class allowing access to the shared elements of the variable in shared memory. More...
#include <arcane/core/MachineShMemWinVariable.h>
Public Member Functions | |
| MachineShMemWinMeshVariableScalarT (MeshVariableScalarRefT< ItemType, DataType > var) | |
| Constructor. | |
| Span< DataType > | view (Int32 rank) const |
| Method allowing retrieval of a view on the variable of another subdomain on the node. | |
| DataType | operator() (Int32 rank, Int32 notlocal_id) |
| Method allowing retrieval of an element of the variable from another subdomain. | |
| void | updateVariable () |
| Method allowing updating this object after a change in the mesh. | |
| Public Member Functions inherited from Arcane::MachineShMemWinVariableCommon | |
| ConstArrayView< Int32 > | machineRanks () const |
| Method allowing retrieval of ranks that possess a segment in the window. | |
| void | barrier () const |
| Method allowing waiting until all processes/threads on the node call this method to continue execution. | |
Additional Inherited Members | |
| Protected Member Functions inherited from Arcane::MachineShMemWinVariableCommon | |
| MachineShMemWinVariableCommon (IVariable *var) | |
| Constructor. | |
| Protected Attributes inherited from Arcane::MachineShMemWinVariableCommon | |
| Ref< MachineShMemWinVariableBase > | m_base |
Class allowing access to the shared elements of the variable in shared memory.
It is necessary that this variable be allocated in shared memory with the property "IVariable::PInShMem".
This class works for mesh scalar variables.
If the mesh changes while an object of this type is used, it is necessary to call the updateVariable() method.
Definition at line 171 of file MachineShMemWinVariable.h.
|
explicit |
Constructor.
| var | Variable having the property "IVariable::PInShMem". |
Definition at line 116 of file MachineShMemWinVariable.cc.
References Arcane::MachineShMemWinVariableCommon::MachineShMemWinVariableCommon(), and updateVariable().
| DataType Arcane::MachineShMemWinMeshVariableScalarT< ItemType, DataType >::operator() | ( | Int32 | rank, |
| Int32 | notlocal_id ) |
Method allowing retrieval of an element of the variable from another subdomain.
Non-collective call.
| rank | The rank of the subdomain of the targeted variable. |
| notlocal_id | The local_id of the subdomain rank. |
Definition at line 145 of file MachineShMemWinVariable.cc.
References view().
| void Arcane::MachineShMemWinMeshVariableScalarT< ItemType, DataType >::updateVariable | ( | ) |
Method allowing updating this object after a change in the mesh.
Collective call.
Definition at line 155 of file MachineShMemWinVariable.cc.
Referenced by MachineShMemWinMeshVariableScalarT().
| Span< DataType > Arcane::MachineShMemWinMeshVariableScalarT< ItemType, DataType >::view | ( | Int32 | rank | ) | const |
Method allowing retrieval of a view on the variable of another subdomain on the node.
Equivalent to "var.asArray()" but for another subdomain.
Non-collective call.
| rank | The rank of the subdomain. |
Definition at line 135 of file MachineShMemWinVariable.cc.
References Arcane::asSpan().
Referenced by operator()().