41 #ifndef __TSQR_MpiCommFactory_hpp
42 #define __TSQR_MpiCommFactory_hpp
45 #include <Tsqr_Config.hpp>
46 #include <Tsqr_MpiMessenger.hpp>
57 template<
class Scalar >
59 makeMpiComm (MPI_Comm comm)
61 return Teuchos::rcp_implicit_cast< MessengerBase< Scalar > >(
new MpiMessenger< Scalar > (comm));
65 #ifdef HAVE_MPI_COMM_NETWORK
66 template<
class Scalar >
72 makeMpiComm (MPI_COMM_NETWORK);
74 #endif // HAVE_MPI_COMM_NETWORK
76 #ifdef HAVE_MPI_COMM_NODE
77 template<
class Scalar >
83 makeMpiComm (MPI_COMM_NODE);
85 #endif // HAVE_MPI_COMM_NODE
91 template<
class Scalar >
95 makeMpiComm (MPI_COMM_WORLD);
101 #endif // __TSQR_MpiCommFactory_hpp