mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-19 02:25:01 +00:00
Make ToVectorTy static.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@231007 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -218,6 +218,15 @@ public:
|
|||||||
R.getInstr()) {}
|
R.getInstr()) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/// A helper function for converting Scalar types to vector types.
|
||||||
|
/// If the incoming type is void, we return void. If the VF is 1, we return
|
||||||
|
/// the scalar type.
|
||||||
|
static Type* ToVectorTy(Type *Scalar, unsigned VF) {
|
||||||
|
if (Scalar->isVoidTy() || VF == 1)
|
||||||
|
return Scalar;
|
||||||
|
return VectorType::get(Scalar, VF);
|
||||||
|
}
|
||||||
|
|
||||||
/// InnerLoopVectorizer vectorizes loops which contain only one basic
|
/// InnerLoopVectorizer vectorizes loops which contain only one basic
|
||||||
/// block to a specified vectorization factor (VF).
|
/// block to a specified vectorization factor (VF).
|
||||||
/// This class performs the widening of scalars into vectors, or multiple
|
/// This class performs the widening of scalars into vectors, or multiple
|
||||||
@@ -958,11 +967,6 @@ private:
|
|||||||
/// width. Vector width of one means scalar.
|
/// width. Vector width of one means scalar.
|
||||||
unsigned getInstructionCost(Instruction *I, unsigned VF);
|
unsigned getInstructionCost(Instruction *I, unsigned VF);
|
||||||
|
|
||||||
/// A helper function for converting Scalar types to vector types.
|
|
||||||
/// If the incoming type is void, we return void. If the VF is 1, we return
|
|
||||||
/// the scalar type.
|
|
||||||
static Type* ToVectorTy(Type *Scalar, unsigned VF);
|
|
||||||
|
|
||||||
/// Returns whether the instruction is a load or store and will be a emitted
|
/// Returns whether the instruction is a load or store and will be a emitted
|
||||||
/// as a vector operation.
|
/// as a vector operation.
|
||||||
bool isConsecutiveLoadOrStore(Instruction *I);
|
bool isConsecutiveLoadOrStore(Instruction *I);
|
||||||
@@ -4994,12 +4998,6 @@ LoopVectorizationCostModel::getInstructionCost(Instruction *I, unsigned VF) {
|
|||||||
}// end of switch.
|
}// end of switch.
|
||||||
}
|
}
|
||||||
|
|
||||||
Type* LoopVectorizationCostModel::ToVectorTy(Type *Scalar, unsigned VF) {
|
|
||||||
if (Scalar->isVoidTy() || VF == 1)
|
|
||||||
return Scalar;
|
|
||||||
return VectorType::get(Scalar, VF);
|
|
||||||
}
|
|
||||||
|
|
||||||
char LoopVectorize::ID = 0;
|
char LoopVectorize::ID = 0;
|
||||||
static const char lv_name[] = "Loop Vectorization";
|
static const char lv_name[] = "Loop Vectorization";
|
||||||
INITIALIZE_PASS_BEGIN(LoopVectorize, LV_NAME, lv_name, false, false)
|
INITIALIZE_PASS_BEGIN(LoopVectorize, LV_NAME, lv_name, false, false)
|
||||||
|
Reference in New Issue
Block a user