mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 08:58:02 +02:00
nir/spirv: Actaully add variables to the funciton or shader
This commit is contained in:
parent
4fa1366392
commit
112c607216
1 changed files with 6 additions and 0 deletions
|
|
@ -497,6 +497,12 @@ vtn_handle_variables(struct vtn_builder *b, SpvOp opcode,
|
|||
vtn_value(b, w[4], vtn_value_type_constant)->constant;
|
||||
}
|
||||
|
||||
if (var->data.mode == nir_var_local) {
|
||||
exec_list_push_tail(&b->impl->locals, &var->node);
|
||||
} else {
|
||||
exec_list_push_tail(&b->shader->globals, &var->node);
|
||||
}
|
||||
|
||||
val->deref = nir_deref_var_create(b->shader, var);
|
||||
|
||||
vtn_foreach_decoration(b, val, var_decoration_cb, var);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue