|
|
Go to the documentation of this file. 1 #ifndef FWCore_Utilities_interface_CMSUnrollLoop_h 2 #define FWCore_Utilities_interface_CMSUnrollLoop_h 6 #if defined(__CUDA_ARCH__) || defined(__HIP_DEVICE_COMPILE__) 9 #define CMS_UNROLL_LOOP _Pragma(EDM_STRINGIZE(unroll)) 10 #define CMS_UNROLL_LOOP_COUNT(N) _Pragma(EDM_STRINGIZE(unroll N)) 11 #define CMS_UNROLL_LOOP_DISABLE _Pragma(EDM_STRINGIZE(unroll 1)) 13 #define CMS_DEVICE_UNROLL_LOOP _Pragma(EDM_STRINGIZE(unroll)) 14 #define CMS_DEVICE_UNROLL_LOOP_COUNT(N) _Pragma(EDM_STRINGIZE(unroll N)) 15 #define CMS_DEVICE_UNROLL_LOOP_DISABLE _Pragma(EDM_STRINGIZE(unroll 1)) 17 #else // defined (__CUDA_ARCH__) || defined (__HIP_DEVICE_COMPILE__) 20 #define CMS_DEVICE_UNROLL_LOOP 21 #define CMS_DEVICE_UNROLL_LOOP_COUNT(N) 22 #define CMS_DEVICE_UNROLL_LOOP_DISABLE 24 #if defined(__clang__) 27 #define CMS_UNROLL_LOOP _Pragma(EDM_STRINGIZE(clang loop unroll(enable))) 28 #define CMS_UNROLL_LOOP_COUNT(N) _Pragma(EDM_STRINGIZE(clang loop unroll_count(N))) 29 #define CMS_UNROLL_LOOP_DISABLE _Pragma(EDM_STRINGIZE(clang loop unroll(disable))) 31 #elif defined(__INTEL_COMPILER) 33 #define CMS_UNROLL_LOOP _Pragma(EDM_STRINGIZE(unroll)) 34 #define CMS_UNROLL_LOOP_COUNT(N) _Pragma(EDM_STRINGIZE(unroll(N))) 35 #define CMS_UNROLL_LOOP_DISABLE _Pragma(EDM_STRINGIZE(nounroll)) 37 #elif defined(__GNUC__) 40 #define CMS_UNROLL_LOOP _Pragma(EDM_STRINGIZE(GCC ivdep)) 41 #define CMS_UNROLL_LOOP_COUNT(N) _Pragma(EDM_STRINGIZE(GCC unroll N)) _Pragma(EDM_STRINGIZE(GCC ivdep)) 42 #define CMS_UNROLL_LOOP_DISABLE _Pragma(EDM_STRINGIZE(GCC unroll 1)) 47 #define CMS_UNROLL_LOOP 48 #define CMS_UNROLL_LOOP_COUNT(N) 49 #define CMS_UNROLL_LOOP_DISABLE 51 #endif // defined(__clang__) || defined(__GNUC__) || ... 53 #endif // defined (__CUDA_ARCH__) || defined (__HIP_DEVICE_COMPILE__) 55 #endif // FWCore_Utilities_interface_CMSUnrollLoop_h