]> granicus.if.org Git - llvm/commitdiff
Merging r229750:
authorTom Stellard <thomas.stellard@amd.com>
Tue, 28 Apr 2015 19:12:12 +0000 (19:12 +0000)
committerTom Stellard <thomas.stellard@amd.com>
Tue, 28 Apr 2015 19:12:12 +0000 (19:12 +0000)
------------------------------------------------------------------------
r229750 | marek.olsak | 2015-02-18 17:12:37 -0500 (Wed, 18 Feb 2015) | 4 lines

R600/SI: Remove explicit VOP operand checking

This should be handled by the OperandType checking.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_36@236018 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/R600/SIInstrInfo.cpp

index c03b17f08fb8d4fd508f719a006e436792c81935..82c8f04164690f00797867d42df16b093ffe20af 100644 (file)
@@ -1216,31 +1216,6 @@ bool SIInstrInfo::verifyInstruction(const MachineInstr *MI,
     }
   }
 
-  // Verify SRC1 for VOP2 and VOPC
-  if (Src1Idx != -1 && (isVOP2(Opcode) || isVOPC(Opcode))) {
-    const MachineOperand &Src1 = MI->getOperand(Src1Idx);
-    if (Src1.isImm()) {
-      ErrInfo = "VOP[2C] src1 cannot be an immediate.";
-      return false;
-    }
-  }
-
-  // Verify VOP3
-  if (isVOP3(Opcode)) {
-    if (Src0Idx != -1 && isLiteralConstant(MI->getOperand(Src0Idx))) {
-      ErrInfo = "VOP3 src0 cannot be a literal constant.";
-      return false;
-    }
-    if (Src1Idx != -1 && isLiteralConstant(MI->getOperand(Src1Idx))) {
-      ErrInfo = "VOP3 src1 cannot be a literal constant.";
-      return false;
-    }
-    if (Src2Idx != -1 && isLiteralConstant(MI->getOperand(Src2Idx))) {
-      ErrInfo = "VOP3 src2 cannot be a literal constant.";
-      return false;
-    }
-  }
-
   // Verify misc. restrictions on specific instructions.
   if (Desc.getOpcode() == AMDGPU::V_DIV_SCALE_F32 ||
       Desc.getOpcode() == AMDGPU::V_DIV_SCALE_F64) {