defined long long and ulonglong
This commit is contained in:
parent
1582180e5b
commit
181ef47053
@ -183,7 +183,9 @@ enum DataType {
|
||||
kLong = 4,
|
||||
kULong = 5,
|
||||
kFloat = 6,
|
||||
kDouble = 7
|
||||
kDouble = 7,
|
||||
kLongLong = 8,
|
||||
kULongLong = 9
|
||||
};
|
||||
} // namespace mpi
|
||||
/*!
|
||||
|
||||
@ -27,19 +27,19 @@ inline DataType GetType<unsigned char>(void) {
|
||||
return kUChar;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<int32_t>(void) {
|
||||
inline DataType GetType<int>(void) {
|
||||
return kInt;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<uint32_t>(void) {
|
||||
inline DataType GetType<unsigned int>(void) {
|
||||
return kUInt;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<int64_t>(void) {
|
||||
inline DataType GetType<long>(void) {
|
||||
return kLong;
|
||||
}
|
||||
template<>
|
||||
inline DataType GetType<uint64_t>(void) {
|
||||
inline DataType GetType<unsigned long>(void) {
|
||||
return kULong;
|
||||
}
|
||||
template<>
|
||||
@ -50,6 +50,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 kLong: return MPI::LONG_LONG;
|
||||
case kULong: return MPI::UNSIGNED_LONG_LONG;
|
||||
}
|
||||
utils::Error("unknown mpi::DataType");
|
||||
return MPI::CHAR;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user