Skip to content

Commit

Permalink
mpiwrap: get rid of unused m_RankMPI, m_SizeMPI in Transport
Browse files Browse the repository at this point in the history
They are unused, since all transports are serial. If someone were
to add a MPI-I/O Transport in the future, it might make sense
to save rank/size within that new derived class, but it's not really
a generically needed thing.
  • Loading branch information
germasch committed Jun 7, 2019
1 parent 616ef7b commit 8b8b4d5
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions source/adios2/toolkit/transport/Transport.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@ Transport::Transport(const std::string type, const std::string library,
MPI_Comm mpiComm, const bool debugMode)
: m_Type(type), m_Library(library), m_MPIComm(mpiComm), m_DebugMode(debugMode)
{
SMPI_Comm_rank(m_MPIComm, &m_RankMPI);
SMPI_Comm_size(m_MPIComm, &m_SizeMPI);
}

void Transport::IWrite(const char *buffer, size_t size, Status &status,
Expand Down
2 changes: 0 additions & 2 deletions source/adios2/toolkit/transport/Transport.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ class Transport
Mode m_OpenMode = Mode::Undefined; ///< at Open from ADIOSTypes.h
bool m_IsOpen = false; ///< true: open for communication, false: unreachable
MPI_Comm m_MPIComm; ///< current MPI communicator
int m_RankMPI = 0; ///< from MPI_Comm_Rank
int m_SizeMPI = 1; ///< from MPI_Comm_Size
profiling::IOChrono m_Profiler; ///< profiles Open, Write/Read, Close

struct Status
Expand Down

1 comment on commit 8b8b4d5

@williamfgc
Copy link
Contributor

@williamfgc williamfgc commented on 8b8b4d5 Jun 7, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@germasch Please don't get rid of this. While not actively developed, shared memory SystemV transports use the rank/size to create a unique key. Because a feature is not used today in production, it doesn't mean it wasn't thought as part of the class abstraction. Thanks.

Please sign in to comment.