[Mesa-dev] [PATCH 3/4] radeonsi: set CB_COLORn_INFO.SIMPLE_FLOAT

Marek Olšák maraeo at gmail.com
Tue Aug 9 23:35:00 UTC 2016


From: Marek Olšák <marek.olsak at amd.com>

This can help enable some blend optimizations (see the register spec).
Vulkan always sets this.
---
 src/gallium/drivers/radeonsi/si_state.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
index 8f7203e..ebd2b7d 100644
--- a/src/gallium/drivers/radeonsi/si_state.c
+++ b/src/gallium/drivers/radeonsi/si_state.c
@@ -2059,20 +2059,21 @@ static void si_initialize_color_surface(struct si_context *sctx,
 	if ((ntype == V_028C70_NUMBER_UINT || ntype == V_028C70_NUMBER_SINT) &&
 	    (format == V_028C70_COLOR_8 ||
 	     format == V_028C70_COLOR_8_8 ||
 	     format == V_028C70_COLOR_8_8_8_8))
 		surf->color_is_int8 = true;
 
 	color_info = S_028C70_FORMAT(format) |
 		S_028C70_COMP_SWAP(swap) |
 		S_028C70_BLEND_CLAMP(blend_clamp) |
 		S_028C70_BLEND_BYPASS(blend_bypass) |
+		S_028C70_SIMPLE_FLOAT(1) |
 		S_028C70_NUMBER_TYPE(ntype) |
 		S_028C70_ENDIAN(endian);
 
 	/* Intensity is implemented as Red, so treat it that way. */
 	color_attrib = S_028C74_FORCE_DST_ALPHA_1(desc->swizzle[3] == PIPE_SWIZZLE_1 ||
 						  util_format_is_intensity(surf->base.format));
 
 	if (rtex->resource.b.b.nr_samples > 1) {
 		unsigned log_samples = util_logbase2(rtex->resource.b.b.nr_samples);
 
-- 
2.7.4



More information about the mesa-dev mailing list