mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-06 01:24:35 +00:00
There are two ways of checking for a given type, for example isa<PointerType>(T)
and T->isPointerTy(). Convert most instances of the first form to the second form. Requested by Chris. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96344 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -78,7 +78,7 @@ static std::vector<unsigned> getShuffleMask(const ShuffleVectorInst *SVI) {
|
||||
/// value is already around as a register, for example if it were inserted then
|
||||
/// extracted from the vector.
|
||||
static Value *FindScalarElement(Value *V, unsigned EltNo) {
|
||||
assert(isa<VectorType>(V->getType()) && "Not looking at a vector?");
|
||||
assert(V->getType()->isVectorTy() && "Not looking at a vector?");
|
||||
const VectorType *PTy = cast<VectorType>(V->getType());
|
||||
unsigned Width = PTy->getNumElements();
|
||||
if (EltNo >= Width) // Out of range access.
|
||||
@ -322,7 +322,7 @@ static bool CollectSingleShuffleElements(Value *V, Value *LHS, Value *RHS,
|
||||
/// that computes V and the LHS value of the shuffle.
|
||||
static Value *CollectShuffleElements(Value *V, std::vector<Constant*> &Mask,
|
||||
Value *&RHS) {
|
||||
assert(isa<VectorType>(V->getType()) &&
|
||||
assert(V->getType()->isVectorTy() &&
|
||||
(RHS == 0 || V->getType() == RHS->getType()) &&
|
||||
"Invalid shuffle!");
|
||||
unsigned NumElts = cast<VectorType>(V->getType())->getNumElements();
|
||||
|
Reference in New Issue
Block a user