Mesa (main): gallivm: fix missing cast in 4-bit blending paths.
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Tue Feb 15 04:26:41 UTC 2022
Module: Mesa
Branch: main
Commit: cb296047f2159390874ac31c6970bacdd72cef16
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=cb296047f2159390874ac31c6970bacdd72cef16
Author: Dave Airlie <airlied at redhat.com>
Date: Fri Feb 11 09:42:40 2022 +1000
gallivm: fix missing cast in 4-bit blending paths.
This got noticed on an llvm debug build.
Reviewed-by: Roland Scheidegger <sroland at vmware.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14987>
---
src/gallium/drivers/llvmpipe/lp_state_fs.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/gallium/drivers/llvmpipe/lp_state_fs.c b/src/gallium/drivers/llvmpipe/lp_state_fs.c
index e775047221a..73b59caff1f 100644
--- a/src/gallium/drivers/llvmpipe/lp_state_fs.c
+++ b/src/gallium/drivers/llvmpipe/lp_state_fs.c
@@ -1700,6 +1700,7 @@ scale_bits(struct gallivm_state *gallivm,
result = lp_build_unsigned_norm_to_float(gallivm, src_bits, flt_type, src);
result = lp_build_clamped_float_to_unsigned_norm(gallivm, flt_type, dst_bits, result);
+ result = LLVMBuildTrunc(gallivm->builder, result, lp_build_int_vec_type(gallivm, src_type), "");
return result;
}
More information about the mesa-commit
mailing list