|
Tpetra Matrix/Vector Services Version of the Day
|
A base class for distributed objects that support import and export operations. More...
#include <Tpetra_DistObject.hpp>

Public Member Functions | |
Constructor/Destructor Methods | |
| DistObject (const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > &map) | |
| constructor | |
| DistObject (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source) | |
| copy constructor | |
| virtual | ~DistObject () |
| destructor | |
Import/Export Methods | |
| void | doImport (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM) |
| Import. | |
| void | doExport (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &dest, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM) |
| Export. | |
| void | doImport (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source, const Export< LocalOrdinal, GlobalOrdinal, Node > &exporter, CombineMode CM) |
| Import (using an Exporter) | |
| void | doExport (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &dest, const Import< LocalOrdinal, GlobalOrdinal, Node > &importer, CombineMode CM) |
| Export (using an Importer) | |
Attribute Accessor Methods | |
| bool | isDistributed () const |
| Accessor for whether or not this is a global object. | |
| const Teuchos::RCP< const Map < LocalOrdinal, GlobalOrdinal, Node > > & | getMap () const |
| Access function for the Tpetra::Map this DistObject was constructed with. | |
I/O methods | |
| void | print (std::ostream &os) const |
| Print method. | |
Protected Types | |
| enum | ReverseOption |
| Enum indicating whether the transer should be performed in forward or reverse mode. More... | |
Protected Member Functions | |
| virtual void | doTransfer (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source, CombineMode CM, size_t numSameIDs, const Teuchos::ArrayView< const LocalOrdinal > &permuteToLIDs, const Teuchos::ArrayView< const LocalOrdinal > &permuteFromLIDs, const Teuchos::ArrayView< const LocalOrdinal > &remoteLIDs, const Teuchos::ArrayView< const LocalOrdinal > &exportLIDs, Distributor &distor, ReverseOption revOp) |
| Perform transfer (redistribution) of data across memory images. | |
| virtual bool | checkSizes (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source)=0 |
| Allows the source and target (this) objects to be compared for compatibility. | |
| virtual void | copyAndPermute (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source, size_t numSameIDs, const Teuchos::ArrayView< const LocalOrdinal > &permuteToLIDs, const Teuchos::ArrayView< const LocalOrdinal > &permuteFromLIDs)=0 |
| Perform copies and permutations that are local to this image. | |
| virtual void | packAndPrepare (const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > &source, const Teuchos::ArrayView< const LocalOrdinal > &exportLIDs, Teuchos::Array< Packet > &exports, const Teuchos::ArrayView< size_t > &numPacketsPerLID, size_t &constantNumPackets, Distributor &distor)=0 |
| Perform any packing or preparation required for communication. | |
| virtual void | unpackAndCombine (const Teuchos::ArrayView< const LocalOrdinal > &importLIDs, const Teuchos::ArrayView< const Packet > &imports, const Teuchos::ArrayView< size_t > &numPacketsPerLID, size_t constantNumPackets, Distributor &distor, CombineMode CM)=0 |
| Perform any unpacking and combining after communication. | |
A base class for distributed objects that support import and export operations.
The DistObject is a base class for all Tpetra distributed global objects. It provides the basic mechanisms and interface specifications for importing and exporting operations using Tpetra::Import and Tpetra::Export objects.
Distributed Global vs. Replicated Local.
Definition at line 65 of file Tpetra_DistObject.hpp.
enum Tpetra::DistObject::ReverseOption [protected] |
Enum indicating whether the transer should be performed in forward or reverse mode.
Definition at line 127 of file Tpetra_DistObject.hpp.
| Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::DistObject | ( | const Teuchos::RCP< const Map< LocalOrdinal, GlobalOrdinal, Node > > & | map | ) | [explicit] |
constructor
Definition at line 239 of file Tpetra_DistObject.hpp.
| Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::DistObject | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source | ) |
copy constructor
Definition at line 244 of file Tpetra_DistObject.hpp.
| Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::~DistObject | ( | ) | [virtual] |
destructor
Definition at line 249 of file Tpetra_DistObject.hpp.
| void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::doImport | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source, |
| const Import< LocalOrdinal, GlobalOrdinal, Node > & | importer, | ||
| CombineMode | CM | ||
| ) |
Definition at line 253 of file Tpetra_DistObject.hpp.
| void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::doExport | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | dest, |
| const Export< LocalOrdinal, GlobalOrdinal, Node > & | exporter, | ||
| CombineMode | CM | ||
| ) |
Definition at line 268 of file Tpetra_DistObject.hpp.
| void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::doImport | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source, |
| const Export< LocalOrdinal, GlobalOrdinal, Node > & | exporter, | ||
| CombineMode | CM | ||
| ) |
Import (using an Exporter)
Definition at line 283 of file Tpetra_DistObject.hpp.
| void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::doExport | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | dest, |
| const Import< LocalOrdinal, GlobalOrdinal, Node > & | importer, | ||
| CombineMode | CM | ||
| ) |
Export (using an Importer)
Definition at line 299 of file Tpetra_DistObject.hpp.
| bool Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::isDistributed | ( | ) | const [inline] |
Accessor for whether or not this is a global object.
Definition at line 314 of file Tpetra_DistObject.hpp.
| const Teuchos::RCP<const Map<LocalOrdinal,GlobalOrdinal,Node> >& Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::getMap | ( | ) | const [inline] |
Access function for the Tpetra::Map this DistObject was constructed with.
Definition at line 111 of file Tpetra_DistObject.hpp.
| void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::print | ( | std::ostream & | os | ) | const |
Print method.
Definition at line 393 of file Tpetra_DistObject.hpp.
| void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::doTransfer | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source, |
| CombineMode | CM, | ||
| size_t | numSameIDs, | ||
| const Teuchos::ArrayView< const LocalOrdinal > & | permuteToLIDs, | ||
| const Teuchos::ArrayView< const LocalOrdinal > & | permuteFromLIDs, | ||
| const Teuchos::ArrayView< const LocalOrdinal > & | remoteLIDs, | ||
| const Teuchos::ArrayView< const LocalOrdinal > & | exportLIDs, | ||
| Distributor & | distor, | ||
| ReverseOption | revOp | ||
| ) | [protected, virtual] |
Perform transfer (redistribution) of data across memory images.
Definition at line 319 of file Tpetra_DistObject.hpp.
| virtual bool Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::checkSizes | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source | ) | [protected, pure virtual] |
Allows the source and target (this) objects to be compared for compatibility.
Return true if they are compatible, return false if they aren't.
Implemented in Tpetra::CrsGraph< LocalOrdinal, GlobalOrdinal, Node, LocalMatOps >, Tpetra::CrsMatrix< Scalar, LocalOrdinal, GlobalOrdinal, Node, LocalMatOps >, and Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
| virtual void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::copyAndPermute | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source, |
| size_t | numSameIDs, | ||
| const Teuchos::ArrayView< const LocalOrdinal > & | permuteToLIDs, | ||
| const Teuchos::ArrayView< const LocalOrdinal > & | permuteFromLIDs | ||
| ) | [protected, pure virtual] |
Perform copies and permutations that are local to this image.
| source | In On entry, the DistObject that we are importing from. |
| numSameIDs | In On entry, the number of elements that are the same on the source and dest objects. (i.e. The element is owned by the same image in both source and dest, and no permutation occurs.) |
| numPermuteIDs | In On entry, the number of elements that are locally permuted between source and dest objects. |
| permuteToLIDs | In On entry, contains a list of the elements that are permuted. (Listed by their LID in the destination DistObject.) |
| permuteFromLIDs | In On entry, contains a list of the elements that are permuted. (Listed by their LID in the source DistObject.) |
Implemented in Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
| virtual void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::packAndPrepare | ( | const DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node > & | source, |
| const Teuchos::ArrayView< const LocalOrdinal > & | exportLIDs, | ||
| Teuchos::Array< Packet > & | exports, | ||
| const Teuchos::ArrayView< size_t > & | numPacketsPerLID, | ||
| size_t & | constantNumPackets, | ||
| Distributor & | distor | ||
| ) | [protected, pure virtual] |
Perform any packing or preparation required for communication.
| source | In On entry, the DistObject that we are importing from. |
| exportLIDs | In On entry, a list of the entries we will be sending to other images. (Listed by their LID in the source DistObject.) |
| exports | Out On exit, buffer for data we will be sending out. |
| numPacketsPerLID | Out On exit, numPacketsPerLID[i] contains the number of packets to be exported for exportLIDs[i]. |
| constantNumPackets | Out On exit, 0 if numPacketsPerLID has variable contents (different size for each LID). If nonzero, then it is expected that num-packets-per-LID is constant, and constantNumPackets holds that value. |
| distor | In On entry, contains the Distributor object we are using. |
Implemented in Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
| virtual void Tpetra::DistObject< Packet, LocalOrdinal, GlobalOrdinal, Node >::unpackAndCombine | ( | const Teuchos::ArrayView< const LocalOrdinal > & | importLIDs, |
| const Teuchos::ArrayView< const Packet > & | imports, | ||
| const Teuchos::ArrayView< size_t > & | numPacketsPerLID, | ||
| size_t | constantNumPackets, | ||
| Distributor & | distor, | ||
| CombineMode | CM | ||
| ) | [protected, pure virtual] |
Perform any unpacking and combining after communication.
| importLIDs | In On entry, a list of the entries we received from other images. (Listed by their LID in the target DistObject.) |
| imports | In Buffer containing data we received. |
| numPacketsPerLID | In numPacketsPerLID[i] contains the number of packets imported for importLIDs[i]. |
| constantNumPackets | In If nonzero, then numPacketsPerLID is constant (same value in all entries) and constantNumPackets is that value. |
| distor | In The Distributor object we are using. |
| CM | In The Tpetra::CombineMode to use when combining the imported entries with existing entries. |
Implemented in Tpetra::MultiVector< Scalar, LocalOrdinal, GlobalOrdinal, Node >.
1.7.4