From e340a8e921088c47753f1b173b92d5e58e8a93fa Mon Sep 17 00:00:00 2001 From: lthakur Date: Tue, 4 Feb 2020 19:37:38 +0530 Subject: [PATCH] [dtest] Update hipLaunchCoopMultiKernel.cpp (#1844) used reinterpret_cast for numBlocks, as expected by hipOccupancyMaxActiveBlocksPerMultiprocessor() api. [ROCm/hip commit: 4d472b777fa6e928f0e2750df75ac1dd6c677e95] --- .../tests/src/runtimeApi/module/hipLaunchCoopMultiKernel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/hip/tests/src/runtimeApi/module/hipLaunchCoopMultiKernel.cpp b/projects/hip/tests/src/runtimeApi/module/hipLaunchCoopMultiKernel.cpp index ea0f41d631..b4d57a7693 100644 --- a/projects/hip/tests/src/runtimeApi/module/hipLaunchCoopMultiKernel.cpp +++ b/projects/hip/tests/src/runtimeApi/module/hipLaunchCoopMultiKernel.cpp @@ -156,7 +156,7 @@ int main() { for (int i = 0; i < nGpu; i++) { HIPCHECK(hipSetDevice(i)); dimBlock.x = workgroups[set]; - HIPCHECK(hipOccupancyMaxActiveBlocksPerMultiprocessor(&numBlocks, + HIPCHECK(hipOccupancyMaxActiveBlocksPerMultiprocessor(reinterpret_cast(&numBlocks), (hipFunction_t)test_gws, dimBlock.x * dimBlock.y * dimBlock.z, dimBlock.x * sizeof(long))); std::cout << "GPU(" << i << ") Block size: " << dimBlock.x << " Num blocks per CU: " << numBlocks << "\n";