]> granicus.if.org Git - llvm/commitdiff
[SystemZ] Remove incorrect assert in SystemZTTIImpl
authorJonas Paulsson <paulsson@linux.vnet.ibm.com>
Thu, 27 Apr 2017 11:01:18 +0000 (11:01 +0000)
committerJonas Paulsson <paulsson@linux.vnet.ibm.com>
Thu, 27 Apr 2017 11:01:18 +0000 (11:01 +0000)
In getCmpSelInstrCost(), CondTy may actually be scalar while ValTy is a
vector when LoopVectorizer is the caller. Therefore the assert that CondTy
must be a vector type if ValTy is was wrong and is now removed.

Review: Ulrich Weigand

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@301533 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/SystemZ/SystemZTargetTransformInfo.cpp

index e74c9a80515d84d8238900e166f6e4061c49f595..d286158f407dda8baa4c2876fa49334fe5de3828 100644 (file)
@@ -676,7 +676,6 @@ int SystemZTTIImpl::getCmpSelInstrCost(unsigned Opcode, Type *ValTy, Type *CondT
                                        const Instruction *I) {
   if (ValTy->isVectorTy()) {
     assert (ST->hasVector() && "getCmpSelInstrCost() called with vector type.");
-    assert (CondTy == nullptr || CondTy->isVectorTy());
     unsigned VF = ValTy->getVectorNumElements();
 
     // Called with a compare instruction.