Arcane  v3.16.7.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
MpiMachineMemoryWindowBaseInternalCreator.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2025 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/* MpiMachineMemoryWindowBaseInternalCreator.h (C) 2000-2025 */
9/* */
10/* Classe permettant de créer des objets de type */
11/* MpiMachineMemoryWindowBaseInternal. */
12/*---------------------------------------------------------------------------*/
13
14#ifndef ARCCORE_MESSAGEPASSINGMPI_INTERNAL_MPIMACHINEMEMORYWINDOWBASEINTERNALCREATOR_H
15#define ARCCORE_MESSAGEPASSINGMPI_INTERNAL_MPIMACHINEMEMORYWINDOWBASEINTERNALCREATOR_H
16
17/*---------------------------------------------------------------------------*/
18/*---------------------------------------------------------------------------*/
19
20#include "arccore/collections/Array.h"
21#include "arccore/message_passing/internal/IMachineMemoryWindowBaseInternal.h"
22
23#include "arccore/message_passing_mpi/MessagePassingMpiGlobal.h"
24
25/*---------------------------------------------------------------------------*/
26/*---------------------------------------------------------------------------*/
27
28namespace Arcane::MessagePassing::Mpi
29{
30
31/*---------------------------------------------------------------------------*/
32/*---------------------------------------------------------------------------*/
33
35
36/*---------------------------------------------------------------------------*/
37/*---------------------------------------------------------------------------*/
38
39class ARCCORE_MESSAGEPASSINGMPI_EXPORT MpiMachineMemoryWindowBaseInternalCreator
40{
41 public:
42
43 explicit MpiMachineMemoryWindowBaseInternalCreator(const MPI_Comm& comm_machine, Int32 comm_machine_rank, Int32 comm_machine_size, const MPI_Comm& comm_world, Int32 comm_world_size);
44
45 ~MpiMachineMemoryWindowBaseInternalCreator() = default;
46
47 public:
48
49 MpiMachineMemoryWindowBaseInternal* createWindow(Int64 sizeof_segment, Int32 sizeof_type) const;
50
51 ConstArrayView<Int32> machineRanks() const;
52
53 private:
54
55 MPI_Comm m_comm_machine;
56 Int32 m_comm_machine_rank;
57 Int32 m_comm_machine_size;
58 UniqueArray<Int32> m_machine_ranks;
59};
60
61/*---------------------------------------------------------------------------*/
62/*---------------------------------------------------------------------------*/
63
64} // namespace Arcane::MessagePassing::Mpi
65
66/*---------------------------------------------------------------------------*/
67/*---------------------------------------------------------------------------*/
68
69#endif
Vue constante d'un tableau de type T.
Vecteur 1D de données avec sémantique par valeur (style STL).
std::int64_t Int64
Type entier signé sur 64 bits.
std::int32_t Int32
Type entier signé sur 32 bits.