Mesa (master): ac/llvm: fix type of second llvm.cttz.* parameter
Dave Airlie
airlied at kemper.freedesktop.org
Tue Jun 27 00:28:47 UTC 2017
Module: Mesa
Branch: master
Commit: b7bd49158e7f5c2084f24ec7b9f877e1af6d1849
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=b7bd49158e7f5c2084f24ec7b9f877e1af6d1849
Author: Nicolai Hähnle <nicolai.haehnle at amd.com>
Date: Sat Jun 24 17:56:38 2017 +0200
ac/llvm: fix type of second llvm.cttz.* parameter
LLVM has required an i1 here for a long time. llvm.ctlz.* was fixed in
commit edd23e06067 ("ac/llvm: fix various findMSB bugs").
Reviewed-by: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>
Signed-off-by: Dave Airlie <airlied at redhat.com>
---
src/amd/common/ac_nir_to_llvm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/amd/common/ac_nir_to_llvm.c b/src/amd/common/ac_nir_to_llvm.c
index f0ae708737..35f66e849d 100644
--- a/src/amd/common/ac_nir_to_llvm.c
+++ b/src/amd/common/ac_nir_to_llvm.c
@@ -1190,7 +1190,7 @@ static LLVMValueRef emit_find_lsb(struct nir_to_llvm_context *ctx,
*
* The hardware already implements the correct behavior.
*/
- LLVMConstInt(ctx->i32, 1, false),
+ LLVMConstInt(ctx->i1, 1, false),
};
return ac_build_intrinsic(&ctx->ac, "llvm.cttz.i32", ctx->i32, params, 2, AC_FUNC_ATTR_READNONE);
}
More information about the mesa-commit
mailing list