Module: Mesa
Branch: master
Commit: 717f55d79d9709a31e0f85a87f076ac13446701d
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=717f55d79d9709a31e0f85a87f076ac13446701d

Author: Christoph Bumiller <e0425...@student.tuwien.ac.at>
Date:   Wed May  9 20:32:44 2012 +0200

nv50/ir: fix reversed order of lane ops in quadops

---

 .../drivers/nv50/codegen/nv50_ir_lowering_nv50.cpp |    5 +++--
 .../drivers/nvc0/codegen/nv50_ir_lowering_nvc0.cpp |    5 +++--
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/src/gallium/drivers/nv50/codegen/nv50_ir_lowering_nv50.cpp 
b/src/gallium/drivers/nv50/codegen/nv50_ir_lowering_nv50.cpp
index 16bba0e..39e0cfa 100644
--- a/src/gallium/drivers/nv50/codegen/nv50_ir_lowering_nv50.cpp
+++ b/src/gallium/drivers/nv50/codegen/nv50_ir_lowering_nv50.cpp
@@ -109,9 +109,10 @@ expandIntegerMUL(BuildUtil *bld, Instruction *mul)
 #define QOP_SUB  2
 #define QOP_MOV2 3
 
+//             UL UR LL LR
 #define QUADOP(q, r, s, t)            \
-   ((QOP_##q << 0) | (QOP_##r << 2) | \
-    (QOP_##s << 4) | (QOP_##t << 6))
+   ((QOP_##q << 6) | (QOP_##r << 4) | \
+    (QOP_##s << 2) | (QOP_##t << 0))
 
 class NV50LegalizePostRA : public Pass
 {
diff --git a/src/gallium/drivers/nvc0/codegen/nv50_ir_lowering_nvc0.cpp 
b/src/gallium/drivers/nvc0/codegen/nv50_ir_lowering_nvc0.cpp
index 900e998..8fd4541 100644
--- a/src/gallium/drivers/nvc0/codegen/nv50_ir_lowering_nvc0.cpp
+++ b/src/gallium/drivers/nvc0/codegen/nv50_ir_lowering_nvc0.cpp
@@ -34,9 +34,10 @@ namespace nv50_ir {
 #define QOP_SUB  2
 #define QOP_MOV2 3
 
+//             UL UR LL LR
 #define QUADOP(q, r, s, t)                      \
-   ((QOP_##q << 0) | (QOP_##r << 2) |           \
-    (QOP_##s << 4) | (QOP_##t << 6))
+   ((QOP_##q << 6) | (QOP_##r << 4) |           \
+    (QOP_##s << 2) | (QOP_##t << 0))
 
 class NVC0LegalizeSSA : public Pass
 {

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to