[Mesa-dev] [PATCH] nir/glsl: Use shader_prog->Name for naming the NIR shader
Kenneth Graunke
kenneth at whitecape.org
Sat Oct 10 22:13:41 PDT 2015
On Friday, October 09, 2015 07:45:20 AM Jason Ekstrand wrote:
> This has the better name to use. Aparently, sh->Name is usually 0.
> ---
> src/glsl/nir/glsl_to_nir.cpp | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/glsl/nir/glsl_to_nir.cpp b/src/glsl/nir/glsl_to_nir.cpp
> index 6e1dd84..3284bdc 100644
> --- a/src/glsl/nir/glsl_to_nir.cpp
> +++ b/src/glsl/nir/glsl_to_nir.cpp
> @@ -150,7 +150,7 @@ glsl_to_nir(const struct gl_shader_program *shader_prog,
> if (sh->Program->SamplersUsed & (1 << i))
> num_textures = i;
>
> - shader->info.name = ralloc_asprintf(shader, "GLSL%d", sh->Name);
> + shader->info.name = ralloc_asprintf(shader, "GLSL%d", shader_prog->Name);
> if (shader_prog->Label)
> shader->info.label = ralloc_strdup(shader, shader_prog->Label);
> shader->info.num_textures = num_textures;
>
Whoops. Right, this is more useful.
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20151010/4f94b688/attachment.sig>
More information about the mesa-dev
mailing list