Skip to content

Commit

Permalink
CUDA: fixes warnings in cuda test files
Browse files Browse the repository at this point in the history
  • Loading branch information
vicentebolea committed Jul 13, 2022
1 parent c326350 commit c4dd3b2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions testing/adios2/engine/bp/TestBPWriteReadCuda.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,11 +140,11 @@ void RateCUDA(const std::string mode)
std::bind(std::minus<float>(), std::placeholders::_1,
INCREMENT));

for (int i = 0; i < NxTotal; i++)
for (size_t i = 0; i < NxTotal; i++)
{
char msg[1 << 8] = {0};
sprintf(msg, "t=%d i=%d rank=%d r32o=%f r32s=%f", t, i, mpiRank,
r32o[i], r32s[i]);
sprintf(msg, "t=%d i=%zu rank=%d r32o=%f r32s=%f", t, i,
mpiRank, r32o[i], r32s[i]);
ASSERT_LT(std::abs(r32o[i] - r32s[i]), EPSILON) << msg;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,11 +125,11 @@ void ZFPRateCUDA(const std::string rate)
std::bind(std::minus<float>(), std::placeholders::_1,
INCREMENT));

for (int i = 0; i < NxTotal; i++)
for (size_t i = 0; i < NxTotal; i++)
{
char msg[1 << 8] = {0};
sprintf(msg, "t=%d i=%d rank=%d r32o=%f r32s=%f", t, i, mpiRank,
r32o[i], r32s[i]);
sprintf(msg, "t=%d i=%zu rank=%d r32o=%f r32s=%f", t, i,
mpiRank, r32o[i], r32s[i]);
ASSERT_LT(std::abs(r32o[i] - r32s[i]), EPSILON) << msg;
}
}
Expand Down

0 comments on commit c4dd3b2

Please sign in to comment.