SNB doesn't have a difinition of 3DSTATE_CONSTANT_BODY, thats why we got segmentation fault when used INTEL_DEBUG=bat. Fixed by avoiding parsing of 3DSTATE_CONSTANT_BODY if gen_spec is not observed.
Fixes: 169d8e011ae (intel: Fix 3DSTATE_CONSTANT buffer decoding.) Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107190 Signed-off-by: Sergii Romantsov <sergii.romant...@globallogic.com> --- src/intel/common/gen_batch_decoder.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/intel/common/gen_batch_decoder.c b/src/intel/common/gen_batch_decoder.c index fe7536d..973221b 100644 --- a/src/intel/common/gen_batch_decoder.c +++ b/src/intel/common/gen_batch_decoder.c @@ -561,6 +561,10 @@ decode_3dstate_constant(struct gen_batch_decode_ctx *ctx, const uint32_t *p) struct gen_group *inst = gen_spec_find_instruction(ctx->spec, p); struct gen_group *body = gen_spec_find_struct(ctx->spec, "3DSTATE_CONSTANT_BODY"); + if (body == NULL) { + fprintf(ctx->fp, "did not find 3DSTATE_CONSTANT_BODY info\n"); + return; + } uint32_t read_length[4] = {0}; uint64_t read_addr[4]; -- 2.7.4 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev