From e9783da3c19a69fb5f3dd46b44c98b00c547631b Mon Sep 17 00:00:00 2001 From: Dittakavi Satyanvesh Date: Fri, 15 May 2020 09:05:06 -0400 Subject: [PATCH] enable occupancy sample on HIP-Clang Change-Id: I236daad743bbbc7f8daa41e8157a4ff73058518b [ROCm/hip commit: 700474db6f92a0acaec2316648ff47b7cc9e28f3] --- projects/hip/samples/2_Cookbook/13_occupancy/occupancy.cpp | 7 ------- 1 file changed, 7 deletions(-) diff --git a/projects/hip/samples/2_Cookbook/13_occupancy/occupancy.cpp b/projects/hip/samples/2_Cookbook/13_occupancy/occupancy.cpp index e772e82b1d..7b32b6d0fa 100644 --- a/projects/hip/samples/2_Cookbook/13_occupancy/occupancy.cpp +++ b/projects/hip/samples/2_Cookbook/13_occupancy/occupancy.cpp @@ -44,8 +44,6 @@ void multiplyCPU(float* C, float* A, float* B, int N){ } } -#if defined(__HIP_PLATFORM_HCC__) && GENERIC_GRID_LAUNCH == 1 && defined(__HCC__) - void launchKernel(float* C, float* A, float* B, bool manual){ hipDeviceProp_t devProp; @@ -95,10 +93,8 @@ void launchKernel(float* C, float* A, float* B, bool manual){ std::cout << "Theoretical Occupancy is " << (double)numBlock* blockSize/devProp.maxThreadsPerMultiProcessor * 100 << "%" << std::endl; } } -#endif int main() { -#if defined(__HIP_PLATFORM_HCC__) && GENERIC_GRID_LAUNCH == 1 && defined(__HCC__) float *A, *B, *C0, *C1, *cpuC; float *Ad, *Bd, *C0d, *C1d; int errors=0; @@ -177,8 +173,5 @@ int main() { free(C0); free(C1); free(cpuC); -#else - std::cout <<"hipOccupancyMaxPotentialBlockSize template not support for Clang compiler"<