Skip to content

Commit c4f7ab1

Browse files
authored
[LV] Initialize IR block pointers in ILV. (NFC) (#139807)
Setting unitialized pointers to nullptr in InnerLoopVectorizer() constructor. These were noticed during a review of the code. Seems like a good idea to clean them up.
1 parent eb5e66b commit c4f7ab1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

llvm/lib/Transforms/Vectorize/LoopVectorize.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -603,13 +603,13 @@ class InnerLoopVectorizer {
603603
// --- Vectorization state ---
604604

605605
/// The vector-loop preheader.
606-
BasicBlock *LoopVectorPreHeader;
606+
BasicBlock *LoopVectorPreHeader = nullptr;
607607

608608
/// The scalar-loop preheader.
609-
BasicBlock *LoopScalarPreHeader;
609+
BasicBlock *LoopScalarPreHeader = nullptr;
610610

611611
/// Middle Block between the vector and the scalar.
612-
BasicBlock *LoopMiddleBlock;
612+
BasicBlock *LoopMiddleBlock = nullptr;
613613

614614
/// A list of all bypass blocks. The first block is the entry of the loop.
615615
SmallVector<BasicBlock *, 4> LoopBypassBlocks;

0 commit comments

Comments
 (0)