From 8b6aec6533cc1fc09e27757aefa8ad3dbd662684 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Michel=20D=C3=A4nzer?= Date: Tue, 27 Nov 2012 19:53:58 +0100 Subject: [PATCH] radeonsi: Bitcast result of packf16 intrinsic to float for export intrinsic. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fixes 7 piglit tests, and prevents many more from crashing. Signed-off-by: Michel Dänzer Reviewed-and-Tested-by: Christian König --- src/gallium/drivers/radeonsi/radeonsi_shader.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/radeonsi/radeonsi_shader.c b/src/gallium/drivers/radeonsi/radeonsi_shader.c index d6e37acaa96..d5d56c46a84 100644 --- a/src/gallium/drivers/radeonsi/radeonsi_shader.c +++ b/src/gallium/drivers/radeonsi/radeonsi_shader.c @@ -496,7 +496,11 @@ static void si_llvm_init_export_args(struct lp_build_tgsi_context *bld_base, LLVMInt32TypeInContext(base->gallivm->context), args, 2, LLVMReadNoneAttribute); - args[chan + 7] = args[chan + 5]; + args[chan + 7] = args[chan + 5] = + LLVMBuildBitCast(base->gallivm->builder, + args[chan + 5], + LLVMFloatTypeInContext(base->gallivm->context), + ""); } /* Set COMPR flag */ -- 2.30.2