mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-31 07:40:11 +01:00
glsl: Add fp16 case for ir_triop_lrp optimization
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3929>
This commit is contained in:
parent
668ab9f19d
commit
83afebf359
1 changed files with 3 additions and 0 deletions
|
|
@ -983,6 +983,9 @@ ir_algebraic_visitor::handle_expression(ir_expression *ir)
|
|||
ir_constant *one;
|
||||
|
||||
switch (ir->type->base_type) {
|
||||
case GLSL_TYPE_FLOAT16:
|
||||
one = new(mem_ctx) ir_constant(float16_t::one(), op2_components);
|
||||
break;
|
||||
case GLSL_TYPE_FLOAT:
|
||||
one = new(mem_ctx) ir_constant(1.0f, op2_components);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue