mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 16:18:06 +02:00
freedreno/a6xx: emit shader names in debug builds
To simplify mapping a shader in a cmdstream trace back to glsl. Signed-off-by: Rob Clark <robdclark@chromium.org> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5280>
This commit is contained in:
parent
541c288b5f
commit
1418ea0d00
1 changed files with 7 additions and 0 deletions
|
|
@ -78,6 +78,13 @@ fd6_emit_shader(struct fd_ringbuffer *ring, const struct ir3_shader_variant *so)
|
|||
unreachable("");
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
/* Name should generally match what you get with MESA_SHADER_CAPTURE_PATH: */
|
||||
const char *name = so->shader->nir->info.name;
|
||||
if (name)
|
||||
fd_emit_string5(ring, name, strlen(name));
|
||||
#endif
|
||||
|
||||
OUT_PKT4(ring, instrlen, 1);
|
||||
OUT_RING(ring, so->instrlen);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue