mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-21 08:17:40 +00:00
Replace some unnecessary vector copies with references.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190770 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -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))
|
||||
|
||||
Reference in New Issue
Block a user