From: Rob Clark Date: Thu, 6 Apr 2017 15:56:23 +0000 (-0400) Subject: nir/print: add compute shader info X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=9fc3e7137ac5566afd3f287ea67c0cdf3c3bfe97;p=mesa.git nir/print: add compute shader info Signed-off-by: Rob Clark Reviewed-by: Alejandro PiƱeiro --- diff --git a/src/compiler/nir/nir_print.c b/src/compiler/nir/nir_print.c index af105557123..e6c5c9c830d 100644 --- a/src/compiler/nir/nir_print.c +++ b/src/compiler/nir/nir_print.c @@ -1169,6 +1169,19 @@ nir_print_shader_annotated(nir_shader *shader, FILE *fp, if (shader->info->label) fprintf(fp, "label: %s\n", shader->info->label); + switch (shader->stage) { + case MESA_SHADER_COMPUTE: + fprintf(fp, "local-size: %u, %u, %u%s\n", + shader->info->cs.local_size[0], + shader->info->cs.local_size[1], + shader->info->cs.local_size[2], + shader->info->cs.local_size_variable ? " (variable)" : ""); + fprintf(fp, "shared-size: %u\n", shader->info->cs.shared_size); + break; + default: + break; + } + fprintf(fp, "inputs: %u\n", shader->num_inputs); fprintf(fp, "outputs: %u\n", shader->num_outputs); fprintf(fp, "uniforms: %u\n", shader->num_uniforms);