aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakub Staszak <kubastaszak@gmail.com>2013-01-25 21:44:27 +0000
committerJakub Staszak <kubastaszak@gmail.com>2013-01-25 21:44:27 +0000
commitb74564a15ac6bfa85c9597bed842b686be1a1a62 (patch)
tree20300cc0e998e4d5965cfccb105e63d444004ed1
parente1f95db4803a48a30fc2a1d5868281a87a36fb85 (diff)
Use const reference instead of vector copying.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173497 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/CodeGen/MachineScheduler.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/CodeGen/MachineScheduler.cpp b/lib/CodeGen/MachineScheduler.cpp
index 821a4f2027..adf9a57dde 100644
--- a/lib/CodeGen/MachineScheduler.cpp
+++ b/lib/CodeGen/MachineScheduler.cpp
@@ -467,7 +467,8 @@ void ScheduleDAGMI::initRegPressure() {
// Cache the list of excess pressure sets in this region. This will also track
// the max pressure in the scheduled code for these sets.
RegionCriticalPSets.clear();
- std::vector<unsigned> RegionPressure = RPTracker.getPressure().MaxSetPressure;
+ const std::vector<unsigned> &RegionPressure =
+ RPTracker.getPressure().MaxSetPressure;
for (unsigned i = 0, e = RegionPressure.size(); i < e; ++i) {
unsigned Limit = TRI->getRegPressureSetLimit(i);
DEBUG(dbgs() << TRI->getRegPressureSetName(i)