glsl: Set the precision of function return value temporaries.

The signature should dictate the precision of the temp we store into.
This ends up ignored by lower_precision for now, which always rewrites it
so as to handle custom lowering of builtin precision..

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21666>
This commit is contained in:
Emma Anholt
2023-03-01 16:02:38 -08:00
committed by Marge Bot
parent b1d228e9d5
commit 18e096769c
+1
View File
@@ -651,6 +651,7 @@ generate_call(exec_list *instructions, ir_function_signature *sig,
ir_variable *var;
var = new(ctx) ir_variable(sig->return_type, name, ir_var_temporary);
var->data.precision = sig->return_precision;
instructions->push_tail(var);
ralloc_free(name);