DistMap::DistMap( Int numSources, mpi::Comm comm ) : numSources_(numSources) { if( comm == mpi::COMM_WORLD ) comm_ = comm; else mpi::Dup( comm, comm_ ); InitializeLocalData(); }
DistMultiVec<T>::DistMultiVec( Int height, Int width, mpi::Comm comm ) : height_(height), width_(width) { if( comm == mpi::COMM_WORLD ) comm_ = comm; else mpi::Dup( comm, comm_ ); InitializeLocalData(); }
DistGraph::DistGraph( Int numSources, Int numTargets, mpi::Comm comm ) : numSources_(numSources), numTargets_(numTargets), commSize_(mpi::Size(comm)), commRank_(mpi::Rank(comm)) { if( comm == mpi::COMM_WORLD ) comm_ = comm; else mpi::Dup( comm, comm_ ); InitializeLocalData(); }
DistMap::DistMap( mpi::Comm comm ) : numSources_(0), commSize_(mpi::Size(comm)), commRank_(mpi::Rank(comm)) { if( comm == mpi::COMM_WORLD ) comm_ = comm; else mpi::Dup( comm, comm_ ); InitializeLocalData(); }
DistMultiVec<T>::DistMultiVec( mpi::Comm comm ) : height_(0), width_(0), commSize_(mpi::Size(comm)), commRank_(mpi::Rank(comm)) { if( comm == mpi::COMM_WORLD ) comm_ = comm; else mpi::Dup( comm, comm_ ); InitializeLocalData(); }
void DistMultiVec<T>::Resize( Int height, Int width ) { if( height_ == height && width == width_ ) return; height_ = height; width_ = width; InitializeLocalData(); SwapClear( remoteUpdates_ ); }
void DistMultiVec<T>::SetComm( mpi::Comm comm ) { if( comm == comm_ ) return; if( comm_ != mpi::COMM_WORLD ) mpi::Free( comm_ ); if( comm == mpi::COMM_WORLD ) comm_ = comm; else mpi::Dup( comm, comm_ ); InitializeLocalData(); }
void DistGraph::Resize( Int numSources, Int numTargets ) { if( numSources_ == numSources && numTargets == numTargets_ ) return; frozenSparsity_ = false; numSources_ = numSources; numTargets_ = numTargets; InitializeLocalData(); SwapClear( remoteSources_ ); SwapClear( remoteTargets_ ); }
void DistMultiVec<T>::Resize( Int height, Int width ) { height_ = height; width_ = width; InitializeLocalData(); }