commit
9520b90c4f
@ -183,7 +183,9 @@ enum DataType {
|
||||
kLong = 4,
|
||||
kULong = 5,
|
||||
kFloat = 6,
|
||||
kDouble = 7
|
||||
kDouble = 7,
|
||||
kLongLong = 8,
|
||||
kULongLong = 9
|
||||
};
|
||||
} // namespace mpi
|
||||
/*!
|
||||
|
||||
@ -30,7 +30,7 @@ inline DataType GetType<int>(void) {
|
||||
return kInt;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<unsigned>(void) {
|
||||
inline DataType GetType<unsigned int>(void) {
|
||||
return kUInt;
|
||||
}
|
||||
template<>
|
||||
@ -49,6 +49,14 @@ template<>
|
||||
inline DataType GetType<double>(void) {
|
||||
return kDouble;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<long long>(void) {
|
||||
return kLongLong;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<unsigned long long>(void) {
|
||||
return kULongLong;
|
||||
}
|
||||
} // namespace mpi
|
||||
} // namespace engine
|
||||
|
||||
|
||||
@ -110,6 +110,8 @@ inline MPI::Datatype GetType(mpi::DataType dtype) {
|
||||
case kULong: return MPI::UNSIGNED_LONG;
|
||||
case kFloat: return MPI::FLOAT;
|
||||
case kDouble: return MPI::DOUBLE;
|
||||
case kLongLong: return MPI::LONG_LONG;
|
||||
case kULongLong: return MPI::UNSIGNED_LONG_LONG;
|
||||
}
|
||||
utils::Error("unknown mpi::DataType");
|
||||
return MPI::CHAR;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user