summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/llvmpipe/lp_flush.c
diff options
context:
space:
mode:
authorKeith Whitwell <keithw@vmware.com>2010-07-08 15:13:35 +0100
committerJosé Fonseca <jfonseca@vmware.com>2010-07-13 17:23:48 +0100
commit3bd9aedbac79eec16bfe6f5fc6f6a021eebe769a (patch)
treeed8c7d28d1d6c7b8cd33b1c68e3ac996c5b64ea8 /src/gallium/drivers/llvmpipe/lp_flush.c
parent6d17f00600ffca7cb39e6f66277cec018ff2c151 (diff)
llvmpipe: move fences from per-bin to per-thread
Rather than inserting an lp_rast_fence command at the end of each bin, have each rasterizer thread call this function directly once it has run out of work to do on a particular scene. This results in fewer calls to the mutex & related functions, but more importantly makes it easier to recognize empty bins.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_flush.c')
-rw-r--r--src/gallium/drivers/llvmpipe/lp_flush.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_flush.c b/src/gallium/drivers/llvmpipe/lp_flush.c
index 0cd288bb73..d78656f462 100644
--- a/src/gallium/drivers/llvmpipe/lp_flush.c
+++ b/src/gallium/drivers/llvmpipe/lp_flush.c
@@ -51,16 +51,8 @@ llvmpipe_flush( struct pipe_context *pipe,
draw_flush(llvmpipe->draw);
- if (fence) {
- /* if we're going to flush the setup/rasterization modules, emit
- * a fence.
- * XXX this (and the code below) may need fine tuning...
- */
- *fence = lp_setup_fence( llvmpipe->setup );
- }
-
/* ask the setup module to flush */
- lp_setup_flush(llvmpipe->setup, flags);
+ lp_setup_flush(llvmpipe->setup, flags, fence);
/* Enable to dump BMPs of the color/depth buffers each frame */
if (0) {