summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/MachineLICM.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2013-09-15 22:04:42 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2013-09-15 22:04:42 +0000
commit7d6052687e847a1d5d5d51efa571f39adb65ca2e (patch)
treea0eef05a4d866a75fd1e302ee36673544d1c7a18 /llvm/lib/CodeGen/MachineLICM.cpp
parentac511cac7779ac44cf23a780b000e6734b05bd17 (diff)
downloadbcm5719-llvm-7d6052687e847a1d5d5d51efa571f39adb65ca2e.tar.gz
bcm5719-llvm-7d6052687e847a1d5d5d51efa571f39adb65ca2e.zip
Replace some unnecessary vector copies with references.
llvm-svn: 190770
Diffstat (limited to 'llvm/lib/CodeGen/MachineLICM.cpp')
-rw-r--r--llvm/lib/CodeGen/MachineLICM.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/MachineLICM.cpp b/llvm/lib/CodeGen/MachineLICM.cpp
index 596b7a3ada9..104eacdb96e 100644
--- a/llvm/lib/CodeGen/MachineLICM.cpp
+++ b/llvm/lib/CodeGen/MachineLICM.cpp
@@ -502,7 +502,7 @@ void MachineLICM::HoistRegionPostRA() {
// Walk the entire region, count number of defs for each register, and
// collect potential LICM candidates.
- const std::vector<MachineBasicBlock*> Blocks = CurLoop->getBlocks();
+ const std::vector<MachineBasicBlock *> &Blocks = CurLoop->getBlocks();
for (unsigned i = 0, e = Blocks.size(); i != e; ++i) {
MachineBasicBlock *BB = Blocks[i];
@@ -584,7 +584,7 @@ void MachineLICM::HoistRegionPostRA() {
/// AddToLiveIns - Add register 'Reg' to the livein sets of BBs in the current
/// loop, and make sure it is not killed by any instructions in the loop.
void MachineLICM::AddToLiveIns(unsigned Reg) {
- const std::vector<MachineBasicBlock*> Blocks = CurLoop->getBlocks();
+ const std::vector<MachineBasicBlock *> &Blocks = CurLoop->getBlocks();
for (unsigned i = 0, e = Blocks.size(); i != e; ++i) {
MachineBasicBlock *BB = Blocks[i];
if (!BB->isLiveIn(Reg))
OpenPOWER on IntegriCloud