glspirv: Don't re-use entry_point pointer from spirv_to_nir

Replace its use with checking for is_entrypoint.

This is a preparation to change spirv_to_nir() return type.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Caio Marcelo de Oliveira Filho
2019-05-18 23:57:25 -07:00
parent c92d002982
commit ee59bac9f4

View File

@@ -251,7 +251,7 @@ _mesa_spirv_to_nir(struct gl_context *ctx,
/* Pick off the single entrypoint that we want */
foreach_list_typed_safe(nir_function, func, node, &nir->functions) {
if (func != entry_point)
if (!func->is_entrypoint)
exec_node_remove(&func->node);
}
assert(exec_list_length(&nir->functions) == 1);