[llvm] r282368 - [SCEV] Reserve space in SmallVector; NFC
Sanjoy Das via llvm-commits
llvm-commits at lists.llvm.org
Sun Sep 25 16:12:09 PDT 2016
Author: sanjoy
Date: Sun Sep 25 18:12:08 2016
New Revision: 282368
URL: http://llvm.org/viewvc/llvm-project?rev=282368&view=rev
Log:
[SCEV] Reserve space in SmallVector; NFC
Modified:
llvm/trunk/lib/Analysis/ScalarEvolution.cpp
Modified: llvm/trunk/lib/Analysis/ScalarEvolution.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Analysis/ScalarEvolution.cpp?rev=282368&r1=282367&r2=282368&view=diff
==============================================================================
--- llvm/trunk/lib/Analysis/ScalarEvolution.cpp (original)
+++ llvm/trunk/lib/Analysis/ScalarEvolution.cpp Sun Sep 25 18:12:08 2016
@@ -5670,6 +5670,7 @@ ScalarEvolution::BackedgeTakenInfo::Back
ArrayRef<ScalarEvolution::EdgeExitInfo> ExitCounts, bool Complete,
const SCEV *MaxCount)
: MaxAndComplete(MaxCount, Complete) {
+ ExitNotTaken.reserve(ExitCounts.size());
std::transform(
ExitCounts.begin(), ExitCounts.end(), std::back_inserter(ExitNotTaken),
[&](const ScalarEvolution::EdgeExitInfo &EEI) {
More information about the llvm-commits
mailing list