summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/llvmpipe/lp_rast_tri.c
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2010-01-15 11:21:16 -0700
committerBrian Paul <brianp@vmware.com>2010-01-15 11:21:16 -0700
commit2797f2bf57562c95a601a67edca3089641215cc4 (patch)
treeff273ffd3535b8cd2805b20524054b89687fd020 /src/gallium/drivers/llvmpipe/lp_rast_tri.c
parent3b1920a34903dfb753bc2a0461fef204d39846c6 (diff)
llvmpipe: generate two shader varients, one omits triangle in/out testing
When we know that a 4x4 pixel block is entirely inside of a triangle use the jit function which omits the in/out test code. Results in a few percent speedup in many tests.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_rast_tri.c')
-rw-r--r--src/gallium/drivers/llvmpipe/lp_rast_tri.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_rast_tri.c b/src/gallium/drivers/llvmpipe/lp_rast_tri.c
index bc7397f50c..9c3f699ec7 100644
--- a/src/gallium/drivers/llvmpipe/lp_rast_tri.c
+++ b/src/gallium/drivers/llvmpipe/lp_rast_tri.c
@@ -89,13 +89,10 @@ block_full_4( struct lp_rasterizer_task *rast_task,
const struct lp_rast_triangle *tri,
int x, int y )
{
- /* Set c1,c2,c3 to large values so the in/out test always passes */
- const int32_t c1 = INT_MIN, c2 = INT_MIN, c3 = INT_MIN;
- lp_rast_shade_quads(rast_task->rast,
- rast_task->thread_index,
- &tri->inputs,
- x, y,
- c1, c2, c3);
+ lp_rast_shade_quads_all(rast_task->rast,
+ rast_task->thread_index,
+ &tri->inputs,
+ x, y);
}