R600: 3 op instructions have no write bit but the result are store in PV
authorVincent Lejeune <vljn@ovi.com>
Mon, 3 Jun 2013 15:56:12 +0000 (15:56 +0000)
committerVincent Lejeune <vljn@ovi.com>
Mon, 3 Jun 2013 15:56:12 +0000 (15:56 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183111 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/R600/R600Packetizer.cpp

index 033c0b410c8d1b1eb9ca268955874247c59d7944..da614c73e1c6fbb2d338a254e73f8ffcfab7741e 100644 (file)
@@ -80,9 +80,7 @@ private:
       if (TII->isTransOnly(BI))
         continue;
       int OperandIdx = TII->getOperandIdx(BI->getOpcode(), R600Operands::WRITE);
-      if (OperandIdx < 0)
-        continue;
-      if (BI->getOperand(OperandIdx).getImm() == 0)
+      if (OperandIdx > -1 && BI->getOperand(OperandIdx).getImm() == 0)
         continue;
       unsigned Dst = BI->getOperand(0).getReg();
       if (BI->getOpcode() == AMDGPU::DOT4_r600 ||