From: Kristian H. Kristensen Date: Tue, 4 Feb 2020 23:50:25 +0000 (-0800) Subject: glsl: Implement constant propagation for fp16 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=505428f20b082f04787630e6d0e5f4dfbce5efb7;p=mesa.git glsl: Implement constant propagation for fp16 Reviewed-by: Ian Romanick Reviewed-by: Marek Olšák Reviewed-by: Alyssa Rosenzweig Part-of: --- diff --git a/src/compiler/glsl/opt_constant_propagation.cpp b/src/compiler/glsl/opt_constant_propagation.cpp index cc57c48c83a..674208348b8 100644 --- a/src/compiler/glsl/opt_constant_propagation.cpp +++ b/src/compiler/glsl/opt_constant_propagation.cpp @@ -208,6 +208,9 @@ ir_constant_propagation_visitor::constant_propagation(ir_rvalue **rvalue) { case GLSL_TYPE_FLOAT: data.f[i] = found->constant->value.f[rhs_channel]; break; + case GLSL_TYPE_FLOAT16: + data.f16[i] = found->constant->value.f16[rhs_channel]; + break; case GLSL_TYPE_DOUBLE: data.d[i] = found->constant->value.d[rhs_channel]; break;