[PATCH] D57957: [NFC] Avoid passing blocks vector to the OutlineRegionInfo constructor by value.
Sergey Dmitriev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 8 15:52:07 PST 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL353582: [NFC] Avoid passing blocks vector to the OutlineRegionInfo constructor by value. (authored by sdmitriev, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D57957?vs=186021&id=186062#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57957/new/
https://reviews.llvm.org/D57957
Files:
llvm/trunk/lib/Transforms/IPO/PartialInlining.cpp
Index: llvm/trunk/lib/Transforms/IPO/PartialInlining.cpp
===================================================================
--- llvm/trunk/lib/Transforms/IPO/PartialInlining.cpp
+++ llvm/trunk/lib/Transforms/IPO/PartialInlining.cpp
@@ -181,11 +181,11 @@
// Container for outline regions
struct OutlineRegionInfo {
- OutlineRegionInfo(SmallVector<BasicBlock *, 8> Region,
+ OutlineRegionInfo(ArrayRef<BasicBlock *> Region,
BasicBlock *EntryBlock, BasicBlock *ExitBlock,
BasicBlock *ReturnBlock)
- : Region(Region), EntryBlock(EntryBlock), ExitBlock(ExitBlock),
- ReturnBlock(ReturnBlock) {}
+ : Region(Region.begin(), Region.end()), EntryBlock(EntryBlock),
+ ExitBlock(ExitBlock), ReturnBlock(ReturnBlock) {}
SmallVector<BasicBlock *, 8> Region;
BasicBlock *EntryBlock;
BasicBlock *ExitBlock;
@@ -535,7 +535,6 @@
// assert(ReturnBlock && "ReturnBlock is NULL somehow!");
FunctionOutliningMultiRegionInfo::OutlineRegionInfo RegInfo(
DominateVector, DominateVector.front(), ExitBlock, ReturnBlock);
- RegInfo.Region = DominateVector;
OutliningInfo->ORI.push_back(RegInfo);
#ifndef NDEBUG
if (TracePartialInlining) {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D57957.186062.patch
Type: text/x-patch
Size: 1266 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190208/6a7ed0f6/attachment.bin>
More information about the llvm-commits
mailing list