@@ -190,37 +190,37 @@ class VPBuilder {
190
190
new VPInstruction (Opcode, Operands, WrapFlags, DL, Name));
191
191
}
192
192
193
- VPValue *createNot (VPValue *Operand, DebugLoc DL = DebugLoc::getUnknown(),
194
- const Twine &Name = "") {
193
+ VPInstruction *createNot (VPValue *Operand, DebugLoc DL = DebugLoc::getUnknown(),
194
+ const Twine &Name = "") {
195
195
return createInstruction (VPInstruction::Not, {Operand}, DL, Name);
196
196
}
197
197
198
- VPValue *createAnd (VPValue *LHS, VPValue *RHS,
199
- DebugLoc DL = DebugLoc::getUnknown(),
200
- const Twine &Name = "") {
198
+ VPInstruction *createAnd (VPValue *LHS, VPValue *RHS,
199
+ DebugLoc DL = DebugLoc::getUnknown(),
200
+ const Twine &Name = "") {
201
201
return createInstruction (Instruction::BinaryOps::And, {LHS, RHS}, DL, Name);
202
202
}
203
203
204
- VPValue *createOr (VPValue *LHS, VPValue *RHS,
205
- DebugLoc DL = DebugLoc::getUnknown(),
206
- const Twine &Name = "") {
204
+ VPInstruction *createOr (VPValue *LHS, VPValue *RHS,
205
+ DebugLoc DL = DebugLoc::getUnknown(),
206
+ const Twine &Name = "") {
207
207
208
208
return tryInsertInstruction (new VPInstruction (
209
209
Instruction::BinaryOps::Or, {LHS, RHS},
210
210
VPRecipeWithIRFlags::DisjointFlagsTy (false ), DL, Name));
211
211
}
212
212
213
- VPValue *createLogicalAnd (VPValue *LHS, VPValue *RHS,
214
- DebugLoc DL = DebugLoc::getUnknown(),
215
- const Twine &Name = "") {
213
+ VPInstruction *createLogicalAnd (VPValue *LHS, VPValue *RHS,
214
+ DebugLoc DL = DebugLoc::getUnknown(),
215
+ const Twine &Name = "") {
216
216
return tryInsertInstruction (
217
217
new VPInstruction (VPInstruction::LogicalAnd, {LHS, RHS}, DL, Name));
218
218
}
219
219
220
- VPValue * createSelect (VPValue *Cond, VPValue *TrueVal, VPValue *FalseVal,
221
- DebugLoc DL = DebugLoc::getUnknown() ,
222
- const Twine &Name = "",
223
- std::optional<FastMathFlags> FMFs = std::nullopt) {
220
+ VPInstruction *
221
+ createSelect (VPValue *Cond, VPValue *TrueVal, VPValue *FalseVal ,
222
+ DebugLoc DL = DebugLoc::getUnknown(), const Twine &Name = "",
223
+ std::optional<FastMathFlags> FMFs = std::nullopt) {
224
224
auto *Select =
225
225
FMFs ? new VPInstruction (Instruction::Select, {Cond, TrueVal, FalseVal},
226
226
*FMFs, DL, Name)
@@ -232,9 +232,9 @@ class VPBuilder {
232
232
// / Create a new ICmp VPInstruction with predicate \p Pred and operands \p A
233
233
// / and \p B.
234
234
// / TODO: add createFCmp when needed.
235
- VPValue *createICmp (CmpInst::Predicate Pred, VPValue *A, VPValue *B,
236
- DebugLoc DL = DebugLoc::getUnknown(),
237
- const Twine &Name = "") {
235
+ VPInstruction *createICmp (CmpInst::Predicate Pred, VPValue *A, VPValue *B,
236
+ DebugLoc DL = DebugLoc::getUnknown(),
237
+ const Twine &Name = "") {
238
238
assert (Pred >= CmpInst::FIRST_ICMP_PREDICATE &&
239
239
Pred <= CmpInst::LAST_ICMP_PREDICATE && " invalid predicate" );
240
240
return tryInsertInstruction (
@@ -248,16 +248,16 @@ class VPBuilder {
248
248
new VPInstruction (VPInstruction::PtrAdd, {Ptr, Offset},
249
249
GEPNoWrapFlags::none (), DL, Name));
250
250
}
251
- VPValue *createInBoundsPtrAdd (VPValue *Ptr, VPValue *Offset,
252
- DebugLoc DL = DebugLoc::getUnknown(),
253
- const Twine &Name = "") {
251
+ VPInstruction *createInBoundsPtrAdd (VPValue *Ptr, VPValue *Offset,
252
+ DebugLoc DL = DebugLoc::getUnknown(),
253
+ const Twine &Name = "") {
254
254
return tryInsertInstruction (
255
255
new VPInstruction (VPInstruction::PtrAdd, {Ptr, Offset},
256
256
GEPNoWrapFlags::inBounds (), DL, Name));
257
257
}
258
258
259
- VPInstruction *createScalarPhi (ArrayRef<VPValue *> IncomingValues,
260
- DebugLoc DL, const Twine &Name = " " ) {
259
+ VPPhi *createScalarPhi (ArrayRef<VPValue *> IncomingValues, DebugLoc DL ,
260
+ const Twine &Name = " " ) {
261
261
return tryInsertInstruction (new VPPhi (IncomingValues, DL, Name));
262
262
}
263
263
0 commit comments