diff --git a/include/hip/hcc_detail/hip_fp16.h b/include/hip/hcc_detail/hip_fp16.h index a718678539..849b7278d8 100644 --- a/include/hip/hcc_detail/hip_fp16.h +++ b/include/hip/hcc_detail/hip_fp16.h @@ -1403,7 +1403,7 @@ THE SOFTWARE. } // Math functions - #if (__hcc_workweek__ >= 19015) || defined(__HIP_CLANG_ONLY__) + #if (__hcc_workweek__ >= 19015) || __HIP_CLANG_ONLY__ inline __device__ float amd_mixed_dot(__half2 a, __half2 b, float c, bool saturate) { diff --git a/include/hip/hcc_detail/hip_fp16_math_fwd.h b/include/hip/hcc_detail/hip_fp16_math_fwd.h index 0c025db786..eeb617c40b 100644 --- a/include/hip/hcc_detail/hip_fp16_math_fwd.h +++ b/include/hip/hcc_detail/hip_fp16_math_fwd.h @@ -53,7 +53,7 @@ extern "C" typedef _Float16 __2f16 __attribute__((ext_vector_type(2))); typedef short __2i16 __attribute__((ext_vector_type(2))); - #if (__hcc_workweek__ >= 19015) || defined(__HIP_CLANG_ONLY__) + #if (__hcc_workweek__ >= 19015) || __HIP_CLANG_ONLY__ __device__ __attribute__((const)) float __ockl_fdot2(__2f16 a, __2f16 b, float c, bool s); #endif diff --git a/include/hip/hcc_detail/math_functions.h b/include/hip/hcc_detail/math_functions.h index 24728550ad..c1f4b7b1b3 100644 --- a/include/hip/hcc_detail/math_functions.h +++ b/include/hip/hcc_detail/math_functions.h @@ -121,7 +121,7 @@ uint64_t __make_mantissa(const char* tagp) } // DOT FUNCTIONS -#if (__hcc_workweek__ >= 19015) || defined(__HIP_CLANG_ONLY__) +#if (__hcc_workweek__ >= 19015) || __HIP_CLANG_ONLY__ __DEVICE__ inline int amd_mixed_dot(short2 a, short2 b, int c, bool saturate) { diff --git a/include/hip/hcc_detail/math_fwd.h b/include/hip/hcc_detail/math_fwd.h index 3021f92d13..64c5f114bb 100644 --- a/include/hip/hcc_detail/math_fwd.h +++ b/include/hip/hcc_detail/math_fwd.h @@ -29,7 +29,7 @@ THE SOFTWARE. #endif // DOT FUNCTIONS -#if (__hcc_workweek__ >= 19015) || defined(__HIP_CLANG_ONLY__) +#if (__hcc_workweek__ >= 19015) || __HIP_CLANG_ONLY__ __device__ __attribute__((const)) int __ockl_sdot2( diff --git a/tests/src/deviceLib/hipTestDotFunctions.cpp b/tests/src/deviceLib/hipTestDotFunctions.cpp index 4dbc12522d..51e005f7fb 100644 --- a/tests/src/deviceLib/hipTestDotFunctions.cpp +++ b/tests/src/deviceLib/hipTestDotFunctions.cpp @@ -32,7 +32,7 @@ THE SOFTWARE. __global__ void DotFunctions(bool* result) { - #if (__hcc_workweek__ >= 19015) || defined(__HIP_CLANG_ONLY__) + #if (__hcc_workweek__ >= 19015) || __HIP_CLANG_ONLY__ // Dot Functions short2 sa{1}, sb{1}; result[0] = amd_mixed_dot(sa, sb, 1, result[0]) && result[0]; diff --git a/tests/src/deviceLib/hipTestNativeHalf.cpp b/tests/src/deviceLib/hipTestNativeHalf.cpp index 3169268dd7..10a3f33a27 100644 --- a/tests/src/deviceLib/hipTestNativeHalf.cpp +++ b/tests/src/deviceLib/hipTestNativeHalf.cpp @@ -157,7 +157,7 @@ void __half2Test(bool* result, __half2 a) { result[0] = !(a < a) && result[0]; result[0] = !(a > a) && result[0]; - #if (__hcc_workweek__ >= 19015) || defined(__HIP_CLANG_ONLY__) + #if (__hcc_workweek__ >= 19015) || __HIP_CLANG_ONLY__ // Dot Functions result[0] = amd_mixed_dot(a, a, 1, 1) && result[0]; #endif