Skip to content

Commit 012079e

Browse files
committed
Refine constructor of VPWidenIntrinsicRecipe
1 parent d020ce0 commit 012079e

File tree

1 file changed

+2
-11
lines changed
  • llvm/lib/Transforms/Vectorize

1 file changed

+2
-11
lines changed

llvm/lib/Transforms/Vectorize/VPlan.h

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1675,17 +1675,8 @@ class VPWidenIntrinsicRecipe : public VPRecipeWithIRFlags {
16751675
VPWidenIntrinsicRecipe(Intrinsic::ID VectorIntrinsicID,
16761676
std::initializer_list<VPValue *> CallArguments,
16771677
Type *Ty, DebugLoc DL = {})
1678-
: VPRecipeWithIRFlags(VPDef::VPWidenIntrinsicSC, CallArguments),
1679-
VectorIntrinsicID(VectorIntrinsicID), ResultTy(Ty) {
1680-
LLVMContext &Ctx = Ty->getContext();
1681-
AttributeList Attrs = Intrinsic::getAttributes(Ctx, VectorIntrinsicID);
1682-
MemoryEffects ME = Attrs.getMemoryEffects();
1683-
MayReadFromMemory = ME.onlyWritesMemory();
1684-
MayWriteToMemory = ME.onlyReadsMemory();
1685-
MayHaveSideEffects = MayWriteToMemory ||
1686-
Attrs.hasFnAttr(Attribute::NoUnwind) ||
1687-
!Attrs.hasFnAttr(Attribute::WillReturn);
1688-
}
1678+
: VPWidenIntrinsicRecipe(VectorIntrinsicID,
1679+
ArrayRef<VPValue *>(CallArguments), Ty, DL) {}
16891680

16901681
~VPWidenIntrinsicRecipe() override = default;
16911682

0 commit comments

Comments
 (0)