X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fintel%2Fcommon%2Fgen_batch_decoder.c;fp=src%2Fintel%2Fcommon%2Fgen_batch_decoder.c;h=ad9cc43e3f7280917c8181d8a2ad9b57cc47aca7;hb=372774367cf5e62f49209716faa80b3ecd932746;hp=3d80b4e6bae90d00b22532d5688fd8192049bf0d;hpb=54ba0daa28b7b3cac8a8df6320cfcf3715e6526b;p=mesa.git diff --git a/src/intel/common/gen_batch_decoder.c b/src/intel/common/gen_batch_decoder.c index 3d80b4e6bae..ad9cc43e3f7 100644 --- a/src/intel/common/gen_batch_decoder.c +++ b/src/intel/common/gen_batch_decoder.c @@ -42,6 +42,7 @@ gen_batch_decode_ctx_init(struct gen_batch_decode_ctx *ctx, { memset(ctx, 0, sizeof(*ctx)); + ctx->devinfo = *devinfo; ctx->get_bo = get_bo; ctx->get_state_size = get_state_size; ctx->user_data = user_data; @@ -54,14 +55,12 @@ gen_batch_decode_ctx_init(struct gen_batch_decode_ctx *ctx, ctx->spec = gen_spec_load(devinfo); else ctx->spec = gen_spec_load_from_path(devinfo, xml_path); - ctx->disasm = gen_disasm_create(devinfo); } void gen_batch_decode_ctx_finish(struct gen_batch_decode_ctx *ctx) { gen_spec_destroy(ctx->spec); - gen_disasm_destroy(ctx->disasm); } #define CSI "\e[" @@ -138,7 +137,7 @@ ctx_disassemble_program(struct gen_batch_decode_ctx *ctx, return; fprintf(ctx->fp, "\nReferenced %s:\n", type); - gen_disasm_disassemble(ctx->disasm, bo.map, 0, ctx->fp); + gen_disassemble(&ctx->devinfo, bo.map, 0, ctx->fp); } /* Heuristic to determine whether a uint32_t is probably actually a float