summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2012-06-04 14:12:15 -0700
committerKenneth Graunke <[email protected]>2012-06-05 14:41:34 -0700
commitcb18472eca9910e7a4222ebc1b6b1b66869f5b53 (patch)
treeab953c44de3dae270be0101259a4fba21c8fa691 /src
parent217b62bf001f6b1da31807b803bbe45d7cabe3ba (diff)
i965/vs: Fix texelFetchOffset() on pre-Gen7.
Commit 4650aea7a536ddce120576fadb91845076e8e37a fixed texelFetchOffset() on Ivybridge, but didn't update the Ironlake/Sandybridge code. +18 piglits on Sandybridge. NOTE: This and 4650aea7a536ddce are both candidates for stable branches. Signed-off-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
index c2b103331aa..cfffef44605 100644
--- a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
+++ b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp
@@ -1838,7 +1838,7 @@ vec4_visitor::visit(ir_texture *ir)
inst->dst = dst_reg(this, ir->type);
inst->shadow_compare = ir->shadow_comparitor != NULL;
- if (ir->offset != NULL && !(intel->gen >= 7 && ir->op == ir_txf))
+ if (ir->offset != NULL && ir->op != ir_txf)
inst->texture_offset = brw_texture_offset(ir->offset->as_constant());
/* MRF for the first parameter */
@@ -1859,7 +1859,7 @@ vec4_visitor::visit(ir_texture *ir)
zero_mask |= (1 << i);
ir->coordinate->accept(this);
- if (ir->offset && intel->gen >= 7 && ir->op == ir_txf) {
+ if (ir->offset && ir->op == ir_txf) {
/* It appears that the ld instruction used for txf does its
* address bounds check before adding in the offset. To work
* around this, just add the integer offset to the integer