9 #ifndef __TSQR_MpiCommFactory_hpp
10 #define __TSQR_MpiCommFactory_hpp
13 #include <Tsqr_Config.hpp>
14 #include <Tsqr_MpiMessenger.hpp>
25 template<
class Scalar >
27 makeMpiComm (MPI_Comm comm)
29 return Teuchos::rcp_implicit_cast< MessengerBase< Scalar > >(
new MpiMessenger< Scalar > (comm));
33 #ifdef HAVE_MPI_COMM_NETWORK
34 template<
class Scalar >
40 makeMpiComm (MPI_COMM_NETWORK);
42 #endif // HAVE_MPI_COMM_NETWORK
44 #ifdef HAVE_MPI_COMM_NODE
45 template<
class Scalar >
51 makeMpiComm (MPI_COMM_NODE);
53 #endif // HAVE_MPI_COMM_NODE
59 template<
class Scalar >
63 makeMpiComm (MPI_COMM_WORLD);
69 #endif // __TSQR_MpiCommFactory_hpp