[PATCH] D139236: [NFC] Cleanup: Replace BB->InstList.splice() with BB->splice()
Vasileios Porpodas via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 2 15:42:27 PST 2022
vporpo created this revision.
vporpo added a reviewer: aeubanks.
Herald added a subscriber: hiraditya.
Herald added a project: All.
vporpo requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
This helps funnel ilist splice() calls into BasicBlock::splice().
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D139236
Files:
llvm/lib/IR/BasicBlock.cpp
Index: llvm/lib/IR/BasicBlock.cpp
===================================================================
--- llvm/lib/IR/BasicBlock.cpp
+++ llvm/lib/IR/BasicBlock.cpp
@@ -415,7 +415,7 @@
DebugLoc Loc = I->getDebugLoc();
// Move all of the specified instructions from the original basic block into
// the new basic block.
- New->getInstList().splice(New->end(), this->getInstList(), I, end());
+ New->splice(New->end(), this, I, end());
// Add a branch instruction to the newly formed basic block.
BranchInst *BI = BranchInst::Create(New, this);
@@ -444,7 +444,7 @@
DebugLoc Loc = I->getDebugLoc();
// Move all of the specified instructions from the original basic block into
// the new basic block.
- New->getInstList().splice(New->end(), this->getInstList(), begin(), I);
+ New->splice(New->end(), this, begin(), I);
// Loop through all of the predecessors of the 'this' block (which will be the
// predecessors of the New block), replace the specified successor 'this'
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D139236.479765.patch
Type: text/x-patch
Size: 1006 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221202/464ffa09/attachment.bin>
More information about the llvm-commits
mailing list