[Mesa-dev] [PATCH 3/5] ac: fix ac_build_bitfield_reverse() for 16-bit integer type
Samuel Pitoiset
samuel.pitoiset at gmail.com
Tue Mar 26 10:34:44 UTC 2019
Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
---
src/amd/common/ac_llvm_build.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/amd/common/ac_llvm_build.c b/src/amd/common/ac_llvm_build.c
index 8046d08d300..b0ce7fc98bd 100644
--- a/src/amd/common/ac_llvm_build.c
+++ b/src/amd/common/ac_llvm_build.c
@@ -2588,6 +2588,8 @@ LLVMValueRef ac_build_bitfield_reverse(struct ac_llvm_context *ctx,
result = ac_build_intrinsic(ctx, "llvm.bitreverse.i16", ctx->i16,
(LLVMValueRef []) { src0 }, 1,
AC_FUNC_ATTR_READNONE);
+
+ result = LLVMBuildZExt(ctx->builder, result, ctx->i32, "");
break;
default:
unreachable(!"invalid bitsize");
--
2.21.0
More information about the mesa-dev
mailing list