[Mesa-dev] [PATCH 6/6] st/mesa: lower DFRACEXP/DLDEXP when they are not supported
Ilia Mirkin
imirkin at alum.mit.edu
Thu Feb 19 15:52:25 PST 2015
Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
---
src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
index e170217..4d91ca6 100644
--- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
+++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp
@@ -5775,6 +5775,9 @@ st_link_shader(struct gl_context *ctx, struct gl_shader_program *prog)
bool have_dround = pscreen->get_shader_param(
pscreen, ptarget,
PIPE_SHADER_CAP_TGSI_DROUND_SUPPORTED);
+ bool have_dfrexp = pscreen->get_shader_param(
+ pscreen, ptarget,
+ PIPE_SHADER_CAP_TGSI_DFRACEXP_DLDEXP_SUPPORTED);
/* If there are forms of indirect addressing that the driver
* cannot handle, perform the lowering pass.
@@ -5812,6 +5815,7 @@ st_link_shader(struct gl_context *ctx, struct gl_shader_program *prog)
EXP_TO_EXP2 |
LOG_TO_LOG2 |
LDEXP_TO_ARITH |
+ (have_dfrexp ? 0 : DFREXP_DLDEXP_TO_ARITH) |
CARRY_TO_ARITH |
BORROW_TO_ARITH |
(have_dround ? 0 : DOPS_TO_DFRAC) |
--
2.0.5
More information about the mesa-dev
mailing list