freedreno/rddecompiler: Make possible to use original shader

Sometimes decompiled shader isn't easily compiled back into the
same binary, e.g. when some part of bitset is not decoded.

Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29753>
This commit is contained in:
Danylo Piliaiev 2024-06-17 17:30:36 +02:00 committed by Marge Bot
parent 9e750f00c3
commit 7c07c44d57

View file

@ -330,7 +330,13 @@ emit_shader_iova(struct replay_context *ctx, struct cmdstream *cs, uint64_t id)
{
uint64_t *shader_iova = (uint64_t *)
_mesa_hash_table_u64_search(ctx->compiled_shaders, id);
pkt_qw(cs, *shader_iova);
if (shader_iova) {
pkt_qw(cs, *shader_iova);
} else {
fprintf(stderr,
"Not override for shader at 0x%" PRIx64 ", using original\n", id);
pkt_qw(cs, id);
}
}
#define begin_draw_state() \