Skip to content

Commit

Permalink
Merge pull request #3481 from anagainaru/pgi-bug
Browse files Browse the repository at this point in the history
Fix build error on Summit for PGI with CUDA backend
  • Loading branch information
anagainaru authored Feb 10, 2023
2 parents 3beac00 + c886ba9 commit 68b40e7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion source/adios2/toolkit/format/bp/bp4/BP4Serializer.tcc
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,8 @@ BP4Serializer::GetBPStats(const bool singleValue,
if (blockInfo.MemSpace == MemorySpace::CUDA)
{
const size_t size = helper::GetTotalSize(blockInfo.Count);
helper::CUDAMinMax(blockInfo.Data, size, stats.Min, stats.Max);
if (!std::is_same<T, long double>::value)
helper::CUDAMinMax(blockInfo.Data, size, stats.Min, stats.Max);
return stats;
}
#endif
Expand Down
5 changes: 3 additions & 2 deletions source/adios2/toolkit/format/bp5/BP5Serializer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -606,8 +606,9 @@ static void GetMinMax(const void *Data, size_t ElemCount, const DataType Type,
Type == helper::GetDataType<T>()) \
{ \
const T *values = (const T *)Data; \
helper::CUDAMinMax(values, ElemCount, MinMax.MinUnion.field_##N, \
MinMax.MaxUnion.field_##N); \
if (!std::is_same<T, long double>::value) \
helper::CUDAMinMax(values, ElemCount, MinMax.MinUnion.field_##N, \
MinMax.MaxUnion.field_##N); \
}
ADIOS2_FOREACH_MINMAX_STDTYPE_2ARGS(pertype)
#undef pertype
Expand Down

0 comments on commit 68b40e7

Please sign in to comment.