|
Tpetra Matrix/Vector Services
Version of the Day
|
Implementation of the Platform concept for MPI-based platforms. More...
#include <Tpetra_MpiPlatform.hpp>

Public Types | |
Typedefs | |
| typedef Node | NodeType |
| Kokkos Node type; the template parameter of this class. More... | |
Public Member Functions | |
Constructors and destructor | |
| MpiPlatform (const RCP< Node > &node) | |
| Constructor that accepts a Kokkos Node. More... | |
| MpiPlatform (const RCP< Node > &node, const RCP< const Teuchos::OpaqueWrapper< MPI_Comm > > &rawMpiComm) | |
| Constructor that accepts a Kokkos Node and a wrapped MPI communicator. More... | |
| MpiPlatform (const RCP< Node > &node, MPI_Comm rawMpiComm) | |
| Constructor that accepts a Kokkos Node and a raw MPI communicator. More... | |
| virtual | ~MpiPlatform () |
| Destructor (virtual for memory safety of derived classes). More... | |
Methods to access the communicator and Kokkos Node. | |
| RCP< const Comm< int > > | getComm () const |
| The Teuchos::Comm instance with which this object was created. More... | |
| RCP< Node > | getNode () const |
| The Kokkos Node instance with which this object was created. More... | |
Protected Attributes | |
| RCP< Teuchos::MpiComm< int > > | comm_ |
| Teuchos::Comm object instantiated for the platform. More... | |
| RCP< Node > | node_ |
| Kokkos Node object instantiated for the platform. More... | |
Implementation of the Platform concept for MPI-based platforms.
MpiPlatform is an implementation of Tpetra's Platform concept. Classes implementing the Platform concept are templated on the Kokkos Node type. They have at least the following public interface:
MpiPlatform also has a constructor that accepts an MPI communicator, over which the application using the platform should perform communication. The default communicator is MPI_COMM_WORLD. MpiPlatform is only available if Trilinos was built with MPI.
Definition at line 75 of file Tpetra_MpiPlatform.hpp.
| typedef Node Tpetra::MpiPlatform< Node >::NodeType |
Kokkos Node type; the template parameter of this class.
Definition at line 81 of file Tpetra_MpiPlatform.hpp.
|
inlineexplicit |
Constructor that accepts a Kokkos Node.
This version of the constructor uses MPI_COMM_WORLD as the communicator. It is declared "explicit" to forbid silent conversions via assignment from the Node instance to an MpiPlatform.
| node | [in/out] The Kokkos Node instance. If null, this class will create a Node with default parameters. |
Definition at line 96 of file Tpetra_MpiPlatform.hpp.
|
inline |
Constructor that accepts a Kokkos Node and a wrapped MPI communicator.
This version of the constructor accepts an arbitrary MPI communicator. It requires that you first wrap the MPI communicator in a Teuchos::OpaqueWrapper. This is helpful if you want to "free" the communicator automatically after use.
If you just have a raw MPI_Comm and you want to be responsible for freeing it after use, use the constructor version that takes a raw MPI_Comm. Otherwise, see the documentation of Teuchos::OpaqueWrapper to learn how to wrap an MPI_Comm and how to set the wrapper to free the communicator automatically after use.
| node | [in/out] The Kokkos Node instance. If null, this class will create a Node with default parameters. |
| rawMpiComm | [in] The MPI communicator, wrapped in a Teuchos::OpaqueWrapper. |
Definition at line 119 of file Tpetra_MpiPlatform.hpp.
|
inline |
Constructor that accepts a Kokkos Node and a raw MPI communicator.
This version of constructor accepts an arbitrary "raw" (not wrapped) MPI communicator. You are responsible for freeing the MPI communicator after use, if necessary.
| node | [in/out] The Kokkos Node instance. If null, this class will create a Node with default parameters. |
| rawMpiComm | [in] The "raw" (not wrapped) MPI communicator. |
Definition at line 135 of file Tpetra_MpiPlatform.hpp.
|
inlinevirtual |
Destructor (virtual for memory safety of derived classes).
Definition at line 141 of file Tpetra_MpiPlatform.hpp.
|
inline |
The Teuchos::Comm instance with which this object was created.
Definition at line 148 of file Tpetra_MpiPlatform.hpp.
|
inline |
The Kokkos Node instance with which this object was created.
Definition at line 153 of file Tpetra_MpiPlatform.hpp.
|
protected |
Teuchos::Comm object instantiated for the platform.
Definition at line 160 of file Tpetra_MpiPlatform.hpp.
|
protected |
Kokkos Node object instantiated for the platform.
Definition at line 162 of file Tpetra_MpiPlatform.hpp.
1.8.11