diff --git a/projects/hip-tests/samples/2_Cookbook/13_occupancy/occupancy.cpp b/projects/hip-tests/samples/2_Cookbook/13_occupancy/occupancy.cpp index 605c7724b2..a9f4e198b0 100644 --- a/projects/hip-tests/samples/2_Cookbook/13_occupancy/occupancy.cpp +++ b/projects/hip-tests/samples/2_Cookbook/13_occupancy/occupancy.cpp @@ -86,8 +86,8 @@ void launchKernel(float* C, float* A, float* B, bool manual){ printf("kernel Execution time = %6.3fms\n", eventMs); //Calculate Occupancy - int numBlock = 0; - HIP_CHECK(hipOccupancyMaxActiveBlocksPerMultiprocessor(&numBlock, multiply,(int)blockSize, 0)); + uint32_t numBlock = 0; + HIP_CHECK(hipOccupancyMaxActiveBlocksPerMultiprocessor(&numBlock, multiply, blockSize, 0)); if(devProp.maxThreadsPerMultiProcessor){ std::cout << "Theoretical Occupancy is " << (double)numBlock* blockSize/devProp.maxThreadsPerMultiProcessor * 100 << "%" << std::endl;