X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/8b3b8b94b252c69516b8ef4ba97596b05033d9ea..083e5bc3e59e935868789304e8bc5d906000a173:/src/smpi/smpi_comm.hpp diff --git a/src/smpi/smpi_comm.hpp b/src/smpi/smpi_comm.hpp index 2c4401394a..9076cc05b0 100644 --- a/src/smpi/smpi_comm.hpp +++ b/src/smpi/smpi_comm.hpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2010-2015. The SimGrid Team. +/* Copyright (c) 2010-2017. The SimGrid Team. * All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it @@ -8,13 +8,7 @@ #define SMPI_COMM_HPP_INCLUDED #include "private.h" - - -typedef struct s_smpi_mpi_comm_key_elem { - MPI_Comm_copy_attr_function* copy_fn; - MPI_Comm_delete_attr_function* delete_fn; -} s_smpi_mpi_comm_key_elem_t; -typedef struct s_smpi_mpi_comm_key_elem *smpi_comm_key_elem; +#include namespace simgrid{ namespace smpi{ @@ -33,7 +27,8 @@ class Comm : public F2C, public Keyval{ int is_uniform_; int* non_uniform_map_; //set if smp nodes have a different number of processes allocated int is_blocked_;// are ranks allocated on the same smp node contiguous ? - xbt_dict_t attributes_; + + std::list rma_wins_; // attached windows for synchronization. public: static std::unordered_map keyvals_; @@ -41,7 +36,6 @@ class Comm : public F2C, public Keyval{ Comm() = default; Comm(MPI_Group group, MPI_Topology topo); - int dup(MPI_Comm* newcomm); MPI_Group group(); MPI_Topology topo(); @@ -57,15 +51,11 @@ class Comm : public F2C, public Keyval{ int is_uniform(); int is_blocked(); MPI_Comm split(int color, int key); - void cleanup_attributes(); void cleanup_smp(); void ref(); static void unref(MPI_Comm comm); static void destroy(MPI_Comm comm); void init_smp(); - int attr_delete(int keyval); - int attr_get(int keyval, void* attr_value, int* flag); - int attr_put(int keyval, void* attr_value); int add_f(); static void free_f(int id); @@ -75,6 +65,10 @@ class Comm : public F2C, public Keyval{ static int keyval_free(int* keyval); static void keyval_cleanup(); + void add_rma_win(MPI_Win win); + void remove_rma_win(MPI_Win win); + void finish_rma_calls(); + }; }