[PATCH] D76542: [Alignment][NFC] Deprecate VectorUtils::getAlignment
Guillaume Chatelet via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Mar 21 04:47:38 PDT 2020
gchatelet created this revision.
gchatelet added a reviewer: courbet.
Herald added subscribers: llvm-commits, rogfer01, hiraditya.
Herald added a project: LLVM.
This is patch is part of a series to introduce an Alignment type.
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2019-July/133851.html
See this patch for the introduction of the type: https://reviews.llvm.org/D64790
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D76542
Files:
llvm/include/llvm/Analysis/VectorUtils.h
llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
llvm/lib/Transforms/Vectorize/VPlan.cpp
Index: llvm/lib/Transforms/Vectorize/VPlan.cpp
===================================================================
--- llvm/lib/Transforms/Vectorize/VPlan.cpp
+++ llvm/lib/Transforms/Vectorize/VPlan.cpp
@@ -844,7 +844,7 @@
auto NewIGIter = Old2New.find(IG);
if (NewIGIter == Old2New.end())
Old2New[IG] = new InterleaveGroup<VPInstruction>(
- IG->getFactor(), IG->isReverse(), Align(IG->getAlignment()));
+ IG->getFactor(), IG->isReverse(), IG->getAlign());
if (Inst == IG->getInsertPos())
Old2New[IG]->setInsertPos(VPInst);
Index: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
===================================================================
--- llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
+++ llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
@@ -5919,7 +5919,7 @@
Group->requiresScalarEpilogue() && !isScalarEpilogueAllowed();
unsigned Cost = TTI.getInterleavedMemoryOpCost(
I->getOpcode(), WideVecTy, Group->getFactor(), Indices,
- Group->getAlignment(), AS, Legal->isMaskRequired(I), UseMaskForGaps);
+ Group->getAlign().value(), AS, Legal->isMaskRequired(I), UseMaskForGaps);
if (Group->isReverse()) {
// TODO: Add support for reversed masked interleaved access.
Index: llvm/include/llvm/Analysis/VectorUtils.h
===================================================================
--- llvm/include/llvm/Analysis/VectorUtils.h
+++ llvm/include/llvm/Analysis/VectorUtils.h
@@ -530,7 +530,10 @@
bool isReverse() const { return Reverse; }
uint32_t getFactor() const { return Factor; }
- uint32_t getAlignment() const { return Alignment.value(); }
+ LLVM_ATTRIBUTE_DEPRECATED(uint32_t getAlignment() const,
+ "Use getAlign instead.") {
+ return Alignment.value();
+ }
Align getAlign() const { return Alignment; }
uint32_t getNumMembers() const { return Members.size(); }
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76542.251835.patch
Type: text/x-patch
Size: 1925 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200321/f540df38/attachment.bin>
More information about the llvm-commits
mailing list