nv50/ir/tgsi: handle DP2 in tgsi Instruction srcMask
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sat, 18 Aug 2012 15:34:44 +0000 (17:34 +0200)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Sat, 18 Aug 2012 15:38:56 +0000 (17:38 +0200)
Solved by Tiziano Bacocco on IRC.

src/gallium/drivers/nv50/codegen/nv50_ir_from_tgsi.cpp

index 16f191da159884a27eba6b558d3c2bf7656ab448..071674b80668a35be5bf2b7a4a03584b16766c2d 100644 (file)
@@ -214,6 +214,8 @@ unsigned int Instruction::srcMask(unsigned int s) const
    case TGSI_OPCODE_COS:
    case TGSI_OPCODE_SIN:
       return (mask & 0x8) | ((mask & 0x7) ? 0x1 : 0x0);
+   case TGSI_OPCODE_DP2:
+      return 0x3;
    case TGSI_OPCODE_DP3:
       return 0x7;
    case TGSI_OPCODE_DP4: