diff options
author | Marek Olšák <[email protected]> | 2011-02-15 05:43:44 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2011-02-15 09:17:39 +0100 |
commit | b9e2cde6006b557a3a23a82384899f4d5a5ac7b8 (patch) | |
tree | a71d951e991ee3161fa1c2acc15ec58a79056caa /src/gallium/drivers/r300/r300_flush.c | |
parent | 8e0437914bb786d0b05be8f95e4ff37bf5a19f44 (diff) |
r300g: offload the CS ioctl to another thread
This is a multi-threading optimization which hides the kernel overhead
behind a thread. It improves performance in CPU-limited apps by 2-15%.
Of course you must have at least 2 cores for it to make any difference.
It can be disabled with:
export RADEON_THREAD=0
Diffstat (limited to 'src/gallium/drivers/r300/r300_flush.c')
-rw-r--r-- | src/gallium/drivers/r300/r300_flush.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r300/r300_flush.c b/src/gallium/drivers/r300/r300_flush.c index bfc15ceae72..c4bb332aec3 100644 --- a/src/gallium/drivers/r300/r300_flush.c +++ b/src/gallium/drivers/r300/r300_flush.c @@ -94,6 +94,10 @@ static void r300_flush(struct pipe_context* pipe, r300->rws->cs_flush(r300->cs); } } + + if (flags & PIPE_FLUSH_FRAME) { + r300->rws->cs_sync_flush(r300->cs); + } } void r300_init_flush_functions(struct r300_context* r300) |