}
struct midgard_disasm_stats
-disassemble_midgard(uint8_t *code, size_t size, unsigned gpu_id)
+disassemble_midgard(uint8_t *code, size_t size, unsigned gpu_id, gl_shader_stage stage)
{
uint32_t *words = (uint32_t *) code;
unsigned num_words = size / 4;
#include <stddef.h>
+#include "compiler/shader_enums.h"
struct midgard_disasm_stats {
/* Counts gleaned from disassembly, or negative if the field cannot be
};
struct midgard_disasm_stats
-disassemble_midgard(uint8_t *code, size_t size, unsigned gpu_id);
+disassemble_midgard(uint8_t *code, size_t size, unsigned gpu_id, gl_shader_stage stage);
program->tls_size = ctx->tls_size;
if (midgard_debug & MIDGARD_DBG_SHADERS)
- disassemble_midgard(program->compiled.data, program->compiled.size, gpu_id);
+ disassemble_midgard(program->compiled.data, program->compiled.size, gpu_id, ctx->stage);
if (midgard_debug & MIDGARD_DBG_SHADERDB) {
unsigned nr_bundles = 0, nr_ins = 0;
stats.quadword_count = 0;
stats.helper_invocations = false;
} else {
- stats = disassemble_midgard(code, sz, gpu_id);
+ stats = disassemble_midgard(code, sz, gpu_id,
+ type == JOB_TYPE_TILER ?
+ MESA_SHADER_FRAGMENT : MESA_SHADER_VERTEX);
}
/* Print shader-db stats */