From 545e4e9e774df6f3d0e295367eea232218c4c120 Mon Sep 17 00:00:00 2001 From: rocking Date: Fri, 17 May 2024 17:19:17 +0800 Subject: [PATCH] Fix compile error (#1292) error: no viable conversion from returned value of type '__half' to function return type 'fp16_hip_t' (aka '_Float16') Co-authored-by: carlushuang [ROCm/composable_kernel commit: aaa8dfdae90f21cd93de170457bebc72a933566d] --- include/ck_tile/core/numeric/half.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/ck_tile/core/numeric/half.hpp b/include/ck_tile/core/numeric/half.hpp index c616b6939f..752145f711 100644 --- a/include/ck_tile/core/numeric/half.hpp +++ b/include/ck_tile/core/numeric/half.hpp @@ -129,8 +129,8 @@ constexpr double fp16_to_double_hip(const fp16_hip_t& x) CK_TILE_HOST_DEVICE constexpr fp16_hip_t float_to_fp16_hip(const float& x) { - return __float2half(x); - // return static_cast(x); + // return __float2half(x); + return static_cast(x); } CK_TILE_HOST_DEVICE