nir/i965/anv/radv/gallium: make shader info a pointer

When restoring something from shader cache we won't have and don't
want to create a nir_shader this change detaches the two.

There are other advantages such as being able to reuse the
shader info populated by GLSL IR.

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
This commit is contained in:
Timothy Arceri
2016-10-13 11:41:23 +11:00
parent 094fe3a959
commit e1af20f18a
65 changed files with 372 additions and 358 deletions
+3 -3
View File
@@ -153,9 +153,9 @@ nir_sweep(nir_shader *nir)
/* First, move ownership of all the memory to a temporary context; assume dead. */
ralloc_adopt(rubbish, nir);
ralloc_steal(nir, (char *)nir->info.name);
if (nir->info.label)
ralloc_steal(nir, (char *)nir->info.label);
ralloc_steal(nir, (char *)nir->info->name);
if (nir->info->label)
ralloc_steal(nir, (char *)nir->info->label);
/* Variables and registers are not dead. Steal them back. */
steal_list(nir, nir_variable, &nir->uniforms);