From 55f80a3290cb0e07db780265369eb504573b4e62 Mon Sep 17 00:00:00 2001 From: Chia-I Wu Date: Thu, 4 Sep 2014 13:56:32 +0800 Subject: ilo: make ilo_cp based on ilo_builder This makes ilo_cp use the builder to manage batch buffers, and use ilo_builder_decode() to replace ilo_3d_pipeline_dump(). --- src/gallium/drivers/ilo/ilo_context.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) (limited to 'src/gallium/drivers/ilo/ilo_context.c') diff --git a/src/gallium/drivers/ilo/ilo_context.c b/src/gallium/drivers/ilo/ilo_context.c index 04df389c6c2..119d940e3f9 100644 --- a/src/gallium/drivers/ilo/ilo_context.c +++ b/src/gallium/drivers/ilo/ilo_context.c @@ -46,13 +46,6 @@ ilo_context_cp_flushed(struct ilo_cp *cp, void *data) { struct ilo_context *ilo = ilo_context(data); - if (ilo->last_cp_bo) - intel_bo_unreference(ilo->last_cp_bo); - - /* remember the just flushed bo, on which fences could wait */ - ilo->last_cp_bo = cp->bo; - intel_bo_reference(ilo->last_cp_bo); - ilo_3d_cp_flushed(ilo->hw3d); } @@ -68,7 +61,7 @@ ilo_flush(struct pipe_context *pipe, if (f) { *f = (struct pipe_fence_handle *) - ilo_fence_create(pipe->screen, ilo->last_cp_bo); + ilo_fence_create(pipe->screen, ilo->cp->last_submitted_bo); } } @@ -79,9 +72,6 @@ ilo_context_destroy(struct pipe_context *pipe) ilo_cleanup_states(ilo); - if (ilo->last_cp_bo) - intel_bo_unreference(ilo->last_cp_bo); - if (ilo->uploader) u_upload_destroy(ilo->uploader); @@ -119,8 +109,7 @@ ilo_context_create(struct pipe_screen *screen, void *priv) util_slab_create(&ilo->transfer_mempool, sizeof(struct ilo_transfer), 64, UTIL_SLAB_SINGLETHREADED); - /* 8192 DWords */ - ilo->cp = ilo_cp_create(ilo->winsys, 8192, is->dev.has_llc); + ilo->cp = ilo_cp_create(ilo->dev, ilo->winsys); ilo->shader_cache = ilo_shader_cache_create(); if (ilo->cp) ilo->hw3d = ilo_3d_create(ilo->cp, ilo->dev); -- cgit v1.2.3