summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/nvc0
diff options
context:
space:
mode:
authorChristoph Bumiller <[email protected]>2012-04-14 04:44:28 +0200
committerChristoph Bumiller <[email protected]>2012-04-14 21:54:04 +0200
commit15ce0f76e2e014374a292550505f58da88333fb7 (patch)
treec179e0962a14b8cd3fac4af7961b92c3b5add4a3 /src/gallium/drivers/nvc0
parentce04221081cd145ac3fc8c053cc5ca0a8f05b7ef (diff)
nv50/ir: fix off-by-ones in CSE and nvc0 insnCanLoad
Diffstat (limited to 'src/gallium/drivers/nvc0')
-rw-r--r--src/gallium/drivers/nvc0/codegen/nv50_ir_target_nvc0.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/nvc0/codegen/nv50_ir_target_nvc0.cpp b/src/gallium/drivers/nvc0/codegen/nv50_ir_target_nvc0.cpp
index 8f34cacd81b..04425623bdb 100644
--- a/src/gallium/drivers/nvc0/codegen/nv50_ir_target_nvc0.cpp
+++ b/src/gallium/drivers/nvc0/codegen/nv50_ir_target_nvc0.cpp
@@ -394,7 +394,7 @@ TargetNVC0::insnCanLoad(const Instruction *i, int s,
if (sf == FILE_IMMEDIATE && ld->getSrc(0)->reg.data.u64 == 0)
return (!i->asTex() && i->op != OP_EXPORT && i->op != OP_STORE);
- if (s > opInfo[i->op].srcNr)
+ if (s >= opInfo[i->op].srcNr)
return false;
if (!(opInfo[i->op].srcFiles[s] & (1 << (int)sf)))
return false;