summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeonsi/si_pipe.c
diff options
context:
space:
mode:
authorNicolai Hähnle <[email protected]>2017-08-04 18:24:33 +0200
committerNicolai Hähnle <[email protected]>2017-08-22 09:53:14 +0200
commit4c3f36ec6b59de2245257c819df7628aaa6bf57b (patch)
treec7e8c49a472da3bf0f0d763044c95feeaf53356a /src/gallium/drivers/radeonsi/si_pipe.c
parentbc933397996c9591ef92cb1eae62e909b111d04f (diff)
radeonsi: print saved CS to the log context
Use the auto logger facility, so that CS chunks will be interleaved with other log info. v2: - fix some crashes when not using CE - fix skipping "previous" chunks of current (unflushed) IB - fix error handling in si_begin_cs_debug Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/radeonsi/si_pipe.c')
-rw-r--r--src/gallium/drivers/radeonsi/si_pipe.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c
index 88fa97d3b0e..93d43e697da 100644
--- a/src/gallium/drivers/radeonsi/si_pipe.c
+++ b/src/gallium/drivers/radeonsi/si_pipe.c
@@ -96,9 +96,7 @@ static void si_destroy_context(struct pipe_context *context)
LLVMDisposeTargetMachine(sctx->tm);
- r600_resource_reference(&sctx->trace_buf, NULL);
- r600_resource_reference(&sctx->last_trace_buf, NULL);
- radeon_clear_saved_cs(&sctx->last_gfx);
+ si_saved_cs_reference(&sctx->current_saved_cs, NULL);
pb_slabs_deinit(&sctx->bindless_descriptor_slabs);
util_dynarray_fini(&sctx->bindless_descriptors);
@@ -163,6 +161,9 @@ static void si_set_log_context(struct pipe_context *ctx,
{
struct si_context *sctx = (struct si_context *)ctx;
sctx->b.log = log;
+
+ if (log)
+ u_log_add_auto_logger(log, si_auto_log_cs, sctx);
}
static struct pipe_context *si_create_context(struct pipe_screen *screen,