mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 08:58:02 +02:00
all: rename gl_shader_stage_name to mesa_shader_stage_name
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com> Acked-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Acked-by: Yonggang Luo <luoyonggang@gmail.com> Acked-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36569>
This commit is contained in:
parent
e0397b1ee0
commit
c135ed1eb9
22 changed files with 25 additions and 25 deletions
|
|
@ -2333,7 +2333,7 @@ vir_get_stage_name(struct v3d_compile *c)
|
|||
else if (c->gs_key && c->gs_key->is_coord)
|
||||
return "MESA_SHADER_GEOMETRY_BIN";
|
||||
else
|
||||
return gl_shader_stage_name(c->s->info.stage);
|
||||
return mesa_shader_stage_name(c->s->info.stage);
|
||||
}
|
||||
|
||||
static inline uint32_t
|
||||
|
|
|
|||
|
|
@ -444,7 +444,7 @@ broadcom_shader_stage_name(enum broadcom_shader_stage stage)
|
|||
case BROADCOM_SHADER_GEOMETRY_BIN:
|
||||
return "MESA_SHADER_GEOMETRY_BIN";
|
||||
default:
|
||||
return gl_shader_stage_name(broadcom_shader_stage_to_gl(stage));
|
||||
return mesa_shader_stage_name(broadcom_shader_stage_to_gl(stage));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2637,7 +2637,7 @@ print_nz_bool(FILE *fp, const char *label, bool value)
|
|||
static void
|
||||
print_shader_info(const struct shader_info *info, FILE *fp)
|
||||
{
|
||||
fprintf(fp, "shader: %s\n", gl_shader_stage_name(info->stage));
|
||||
fprintf(fp, "shader: %s\n", mesa_shader_stage_name(info->stage));
|
||||
|
||||
if (memcmp(info->source_blake3, &(blake3_hash){ 0 }, sizeof(info->source_blake3))) {
|
||||
fprintf(fp, "source_blake3: {");
|
||||
|
|
@ -2662,9 +2662,9 @@ print_shader_info(const struct shader_info *info, FILE *fp)
|
|||
}
|
||||
|
||||
if (info->prev_stage != MESA_SHADER_NONE)
|
||||
fprintf(fp, "prev_stage: %s\n", gl_shader_stage_name(info->prev_stage));
|
||||
fprintf(fp, "prev_stage: %s\n", mesa_shader_stage_name(info->prev_stage));
|
||||
if (info->next_stage != MESA_SHADER_NONE)
|
||||
fprintf(fp, "next_stage: %s\n", gl_shader_stage_name(info->next_stage));
|
||||
fprintf(fp, "next_stage: %s\n", mesa_shader_stage_name(info->next_stage));
|
||||
|
||||
print_nz_unsigned(fp, "num_textures", info->num_textures);
|
||||
print_nz_unsigned(fp, "num_ubos", info->num_ubos);
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
#define NAME(val) ((((val) < ARRAY_SIZE(names)) && names[(val)]) ? names[(val)] : "UNKNOWN")
|
||||
|
||||
const char *
|
||||
gl_shader_stage_name(mesa_shader_stage stage)
|
||||
mesa_shader_stage_name(mesa_shader_stage stage)
|
||||
{
|
||||
static const char *names[] = {
|
||||
ENUM(MESA_SHADER_VERTEX),
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ mesa_shader_stage_can_set_fragment_shading_rate(mesa_shader_stage stage)
|
|||
|
||||
typedef short gl_state_index16; /* see enum gl_state_index */
|
||||
|
||||
const char *gl_shader_stage_name(mesa_shader_stage stage);
|
||||
const char *mesa_shader_stage_name(mesa_shader_stage stage);
|
||||
|
||||
/**
|
||||
* Translate a mesa_shader_stage to a short shader stage name for debug
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ extern "C" {
|
|||
static inline const char *
|
||||
tr_util_mesa_shader_stage_name(mesa_shader_stage stage)
|
||||
{
|
||||
return gl_shader_stage_name(stage);
|
||||
return mesa_shader_stage_name(stage);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -951,7 +951,7 @@ crocus_setup_binding_table(const struct intel_device_info *devinfo,
|
|||
bt->size_bytes = next * 4;
|
||||
|
||||
if (INTEL_DEBUG(DEBUG_BT)) {
|
||||
crocus_print_binding_table(stderr, gl_shader_stage_name(info->stage), bt);
|
||||
crocus_print_binding_table(stderr, mesa_shader_stage_name(info->stage), bt);
|
||||
}
|
||||
|
||||
/* Apply the binding table indices. The backend compiler is not expected
|
||||
|
|
|
|||
|
|
@ -1519,7 +1519,7 @@ iris_setup_binding_table(const struct intel_device_info *devinfo,
|
|||
bt->size_bytes = next * 4;
|
||||
|
||||
if (INTEL_DEBUG(DEBUG_BT)) {
|
||||
iris_print_binding_table(stderr, gl_shader_stage_name(info->stage), bt);
|
||||
iris_print_binding_table(stderr, mesa_shader_stage_name(info->stage), bt);
|
||||
}
|
||||
|
||||
/* Apply the binding table indices. The backend compiler is not expected
|
||||
|
|
|
|||
|
|
@ -425,7 +425,7 @@ static void gpir_print_shader_db(struct nir_shader *nir, gpir_compiler *comp,
|
|||
char *shaderdb;
|
||||
ASSERTED int ret = asprintf(&shaderdb,
|
||||
"%s shader: %d inst, %d loops, %d:%d spills:fills\n",
|
||||
gl_shader_stage_name(info->stage),
|
||||
mesa_shader_stage_name(info->stage),
|
||||
comp->num_instr,
|
||||
comp->num_loops,
|
||||
comp->num_spills,
|
||||
|
|
|
|||
|
|
@ -964,7 +964,7 @@ static void ppir_print_shader_db(struct nir_shader *nir, ppir_compiler *comp,
|
|||
char *shaderdb;
|
||||
ASSERTED int ret = asprintf(&shaderdb,
|
||||
"%s shader: %d inst, %d loops, %d:%d spills:fills\n",
|
||||
gl_shader_stage_name(info->stage),
|
||||
mesa_shader_stage_name(info->stage),
|
||||
comp->cur_instr_index,
|
||||
comp->num_loops,
|
||||
comp->num_spills,
|
||||
|
|
|
|||
|
|
@ -225,7 +225,7 @@ panfrost_shader_compile(struct panfrost_screen *screen, const nir_shader *ir,
|
|||
|
||||
screen->vtbl.compile_shader(s, &inputs, &out->binary, &out->info);
|
||||
|
||||
pan_stats_util_debug(dbg, gl_shader_stage_name(s->info.stage),
|
||||
pan_stats_util_debug(dbg, mesa_shader_stage_name(s->info.stage),
|
||||
&out->info.stats);
|
||||
|
||||
if (s->info.stage == MESA_SHADER_VERTEX && out->info.vs.idvs) {
|
||||
|
|
|
|||
|
|
@ -3393,7 +3393,7 @@ static void si_init_shader_selector_async(void *job, void *gdata, int thread_ind
|
|||
mesa_loge("can't compile a main shader part (type: %s).\n"
|
||||
"This is probably a driver bug, please report "
|
||||
"it to https://gitlab.freedesktop.org/mesa/mesa/-/issues.",
|
||||
gl_shader_stage_name(shader->selector->stage));
|
||||
mesa_shader_stage_name(shader->selector->stage));
|
||||
FREE(shader);
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -422,7 +422,7 @@ v3d_uncompiled_shader_create(struct pipe_context *pctx,
|
|||
|
||||
if (V3D_DBG(NIR) || v3d_debug_flag_for_shader_stage(s->info.stage)) {
|
||||
fprintf(stderr, "%s prog %d NIR:\n",
|
||||
gl_shader_stage_name(s->info.stage),
|
||||
mesa_shader_stage_name(s->info.stage),
|
||||
so->program_id);
|
||||
nir_print_shader(s, stderr);
|
||||
fprintf(stderr, "\n");
|
||||
|
|
|
|||
|
|
@ -2538,7 +2538,7 @@ vc4_shader_state_create(struct pipe_context *pctx,
|
|||
|
||||
if (VC4_DBG(NIR)) {
|
||||
fprintf(stderr, "%s prog %d NIR:\n",
|
||||
gl_shader_stage_name(s->info.stage),
|
||||
mesa_shader_stage_name(s->info.stage),
|
||||
so->program_id);
|
||||
nir_print_shader(s, stderr);
|
||||
fprintf(stderr, "\n");
|
||||
|
|
|
|||
|
|
@ -1059,7 +1059,7 @@ static void _pco_print_shader_info(pco_print_state *state, pco_shader *shader)
|
|||
{
|
||||
if (shader->name)
|
||||
pco_printfi(state, "name: \"%s\"\n", shader->name);
|
||||
pco_printfi(state, "stage: %s\n", gl_shader_stage_name(shader->stage));
|
||||
pco_printfi(state, "stage: %s\n", mesa_shader_stage_name(shader->stage));
|
||||
pco_printfi(state, "internal: %s\n", true_false_str(shader->is_internal));
|
||||
/* TODO: more info/stats, e.g. temps/other regs used, etc.? */
|
||||
}
|
||||
|
|
|
|||
|
|
@ -138,7 +138,7 @@ brw_compile_bs(const struct brw_compiler *compiler,
|
|||
"%s %s shader %s",
|
||||
shader->info.label ?
|
||||
shader->info.label : "unnamed",
|
||||
gl_shader_stage_name(shader->info.stage),
|
||||
mesa_shader_stage_name(shader->info.stage),
|
||||
shader->info.name);
|
||||
g.enable_debug(name);
|
||||
}
|
||||
|
|
@ -157,7 +157,7 @@ brw_compile_bs(const struct brw_compiler *compiler,
|
|||
"%s %s resume(%u) shader %s",
|
||||
shader->info.label ?
|
||||
shader->info.label : "unnamed",
|
||||
gl_shader_stage_name(shader->info.stage),
|
||||
mesa_shader_stage_name(shader->info.stage),
|
||||
i, shader->info.name);
|
||||
g.enable_debug(name);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -409,7 +409,7 @@ brw_print_vue_map(FILE *fp, const struct intel_vue_map *vue_map,
|
|||
}
|
||||
} else {
|
||||
fprintf(fp, "%s VUE map (%d slots, %s)\n",
|
||||
gl_shader_stage_name(stage), vue_map->num_slots, layout_name);
|
||||
mesa_shader_stage_name(stage), vue_map->num_slots, layout_name);
|
||||
for (int i = 0; i < vue_map->num_slots; i++) {
|
||||
fprintf(fp, " [%02d] %s\n", i,
|
||||
varying_name(vue_map->slot_to_varying[i], stage));
|
||||
|
|
|
|||
|
|
@ -370,7 +370,7 @@ anv_nir_compute_push_layout(nir_shader *nir,
|
|||
}
|
||||
|
||||
#if 0
|
||||
fprintf(stderr, "stage=%s push ranges:\n", gl_shader_stage_name(nir->info.stage));
|
||||
fprintf(stderr, "stage=%s push ranges:\n", mesa_shader_stage_name(nir->info.stage));
|
||||
for (unsigned i = 0; i < ARRAY_SIZE(map->push_ranges); i++)
|
||||
fprintf(stderr, " range%i: %03u-%03u set=%u index=%u\n", i,
|
||||
map->push_ranges[i].start,
|
||||
|
|
|
|||
|
|
@ -92,7 +92,7 @@ anv_shader_stage_to_nir(struct anv_device *device,
|
|||
/* src_hash is unknown at the point */
|
||||
if (!intel_shader_dump_filter) {
|
||||
fprintf(stderr, "NIR (from SPIR-V) for %s shader:\n",
|
||||
gl_shader_stage_name(stage));
|
||||
mesa_shader_stage_name(stage));
|
||||
nir_print_shader(nir, stderr);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -141,7 +141,7 @@ anv_shader_bin_create(struct anv_device *device,
|
|||
|
||||
shader->stage = stage;
|
||||
if(INTEL_DEBUG(DEBUG_SHOW_SHADER_STAGE))
|
||||
fprintf(stderr, "Stage: %s\n", gl_shader_stage_name(shader->stage));
|
||||
fprintf(stderr, "Stage: %s\n", mesa_shader_stage_name(shader->stage));
|
||||
|
||||
shader->kernel =
|
||||
anv_state_pool_alloc(&device->instruction_state_pool, kernel_size, 64);
|
||||
|
|
|
|||
|
|
@ -85,7 +85,7 @@ anv_shader_stage_to_nir(struct anv_device *device,
|
|||
|
||||
if (INTEL_DEBUG(intel_debug_flag_for_shader_stage(stage))) {
|
||||
fprintf(stderr, "NIR (from SPIR-V) for %s shader:\n",
|
||||
gl_shader_stage_name(stage));
|
||||
mesa_shader_stage_name(stage));
|
||||
nir_print_shader(nir, stderr);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -5015,7 +5015,7 @@ bi_shader_stage_name(bi_context *ctx)
|
|||
else if (ctx->inputs->is_blend)
|
||||
return "MESA_SHADER_BLEND";
|
||||
else
|
||||
return gl_shader_stage_name(ctx->stage);
|
||||
return mesa_shader_stage_name(ctx->stage);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue