]> granicus.if.org Git - clang/commitdiff
AArch64: use less cluttered intrinsic for vtbl/vtbx
authorTim Northover <tnorthover@apple.com>
Wed, 26 Feb 2014 11:55:15 +0000 (11:55 +0000)
committerTim Northover <tnorthover@apple.com>
Wed, 26 Feb 2014 11:55:15 +0000 (11:55 +0000)
The table is always 128-bit so there's no reason to specify it every time we
want the intrinsic.

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

lib/CodeGen/CGBuiltin.cpp

index 020dc8da993752f73c149c1da94797291080b51f..8bc5134fb6fd77bd4801019d96d945f6e17d7548 100644 (file)
@@ -3120,11 +3120,10 @@ static Value *packTBLDVectorList(CodeGenFunction &CGF, ArrayRef<Value *> Ops,
 
   TblTy = llvm::VectorType::get(TblTy->getElementType(),
                                 2*TblTy->getNumElements());
-  llvm::Type *Tys[2] = { ResTy, TblTy };
 
   Function *TblF;
   TblOps.push_back(IndexOp);
-  TblF = CGF.CGM.getIntrinsic(IntID, Tys);
+  TblF = CGF.CGM.getIntrinsic(IntID, ResTy);
   
   return CGF.EmitNeonCall(TblF, TblOps, Name);
 }
@@ -3190,9 +3189,6 @@ static Value *EmitAArch64TblBuiltinExpr(CodeGenFunction &CGF,
   }
 
   Arg = E->getArg(TblPos);
-  llvm::Type *TblTy = CGF.ConvertType(Arg->getType());
-  llvm::VectorType *VTblTy = cast<llvm::VectorType>(TblTy);
-  llvm::Type *Tys[2] = { Ty, VTblTy };
   unsigned nElts = VTy->getNumElements();  
 
   // AArch64 scalar builtins are not overloaded, they do not have an extra
@@ -3306,7 +3302,7 @@ static Value *EmitAArch64TblBuiltinExpr(CodeGenFunction &CGF,
   if (!Int)
     return 0;
 
-  Function *F = CGF.CGM.getIntrinsic(Int, Tys);
+  Function *F = CGF.CGM.getIntrinsic(Int, Ty);
   return CGF.EmitNeonCall(F, Ops, s);
 }