$extrastylesheet
#include <parallel_implementation.h>

Public Member Functions | |
| StandardType (const std::pair< T1, T2 > *example=NULL) | |
| ~StandardType () | |
| operator const data_type & () const | |
| operator data_type & () | |
| void | commit () |
| void | free () |
Protected Attributes | |
| data_type | _datatype |
Definition at line 117 of file parallel_implementation.h.
| libMesh::Parallel::StandardType< std::pair< T1, T2 > >::StandardType | ( | const std::pair< T1, T2 > * | example = NULL | ) | [inline, explicit] |
Definition at line 121 of file parallel_implementation.h.
References libMesh::Parallel::DataType::_datatype, and libMesh::libmesh_assert().
{
// We need an example for MPI_Address to use
libmesh_assert(example);
#ifdef LIBMESH_HAVE_MPI
// Get the sub-data-types, and make sure they live long enough
// to construct the derived type
StandardType<T1> d1(&example->first);
StandardType<T2> d2(&example->second);
MPI_Datatype types[] = { (data_type)d1, (data_type)d2 };
int blocklengths[] = {1,1};
MPI_Aint displs[2];
#if MPI_VERSION > 1
MPI_Get_address (const_cast<T1*>(&example->first), &displs[0]);
MPI_Get_address (const_cast<T2*>(&example->second), &displs[1]);
#else
MPI_Address (const_cast<T1*>(&example->first), &displs[0]);
MPI_Address (const_cast<T2*>(&example->second), &displs[1]);
#endif
displs[1] -= displs[0];
displs[0] = 0;
#if MPI_VERSION > 1
MPI_Type_create_struct (2, blocklengths, displs, types, &_datatype);
#else
MPI_Type_struct (2, blocklengths, displs, types, &_datatype);
#endif // #if MPI_VERSION > 1
MPI_Type_commit (&_datatype);
#endif // LIBMESH_HAVE_MPI
}
| libMesh::Parallel::StandardType< std::pair< T1, T2 > >::~StandardType | ( | ) | [inline] |
Definition at line 153 of file parallel_implementation.h.
References libMesh::Parallel::DataType::free().
{ this->free(); }
| void libMesh::Parallel::DataType::commit | ( | ) | [inline, inherited] |
Definition at line 278 of file parallel.h.
References libMesh::Parallel::DataType::_datatype.
Referenced by libMesh::Parallel::DataType::DataType().
{
#ifdef LIBMESH_HAVE_MPI
MPI_Type_commit (&_datatype);
#endif
}
| void libMesh::Parallel::DataType::free | ( | ) | [inline, inherited] |
Definition at line 285 of file parallel.h.
References libMesh::Parallel::DataType::_datatype.
Referenced by ~StandardType(), libMesh::Parallel::StandardType< std::complex< T > >::~StandardType(), libMesh::Parallel::StandardType< TypeTensor< T > >::~StandardType(), and libMesh::Parallel::StandardType< TensorValue< T > >::~StandardType().
{
#ifdef LIBMESH_HAVE_MPI
MPI_Type_free (&_datatype);
#endif
}
| libMesh::Parallel::DataType::operator const data_type & | ( | ) | const [inline, inherited] |
Definition at line 266 of file parallel.h.
References libMesh::Parallel::DataType::_datatype.
{ return _datatype; }
| libMesh::Parallel::DataType::operator data_type & | ( | ) | [inline, inherited] |
Definition at line 269 of file parallel.h.
References libMesh::Parallel::DataType::_datatype.
{ return _datatype; }
data_type libMesh::Parallel::DataType::_datatype [protected, inherited] |
Definition at line 294 of file parallel.h.
Referenced by libMesh::Parallel::DataType::commit(), libMesh::Parallel::DataType::DataType(), libMesh::Parallel::DataType::free(), libMesh::Parallel::DataType::operator const data_type &(), libMesh::Parallel::DataType::operator data_type &(), libMesh::Parallel::DataType::operator=(), libMesh::Parallel::StandardType< Hilbert::HilbertIndices >::StandardType(), libMesh::Parallel::StandardType< TypeVector< T > >::StandardType(), StandardType(), libMesh::Parallel::StandardType< VectorValue< T > >::StandardType(), and libMesh::Parallel::StandardType< Point >::StandardType().