diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2016-06-12 15:39:02 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2016-06-12 15:39:02 +0000 |
commit | bdc4956bac81a93d541bc2fab0fdcc7ffdeb5cdd (patch) | |
tree | 61f67bbd45f92949e27d34efcead9e0e16d5dfea /llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp | |
parent | 977530a8c9e3e201f8094df9ab2306b1e699d821 (diff) | |
download | bcm5719-llvm-bdc4956bac81a93d541bc2fab0fdcc7ffdeb5cdd.tar.gz bcm5719-llvm-bdc4956bac81a93d541bc2fab0fdcc7ffdeb5cdd.zip |
Pass DebugLoc and SDLoc by const ref.
This used to be free, copying and moving DebugLocs became expensive
after the metadata rewrite. Passing by reference eliminates a ton of
track/untrack operations. No functionality change intended.
llvm-svn: 272512
Diffstat (limited to 'llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp')
-rw-r--r-- | llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp b/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp index 0a84f088e26..76361b85bf4 100644 --- a/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp +++ b/llvm/lib/Target/Mips/MipsDelaySlotFiller.cpp @@ -224,8 +224,8 @@ namespace { private: bool runOnMachineBasicBlock(MachineBasicBlock &MBB); - Iter replaceWithCompactBranch(MachineBasicBlock &MBB, - Iter Branch, DebugLoc DL); + Iter replaceWithCompactBranch(MachineBasicBlock &MBB, Iter Branch, + const DebugLoc &DL); /// This function checks if it is valid to move Candidate to the delay slot /// and returns true if it isn't. It also updates memory and register @@ -529,8 +529,8 @@ getUnderlyingObjects(const MachineInstr &MI, } // Replace Branch with the compact branch instruction. -Iter Filler::replaceWithCompactBranch(MachineBasicBlock &MBB, - Iter Branch, DebugLoc DL) { +Iter Filler::replaceWithCompactBranch(MachineBasicBlock &MBB, Iter Branch, + const DebugLoc &DL) { const MipsSubtarget &STI = MBB.getParent()->getSubtarget<MipsSubtarget>(); const MipsInstrInfo *TII = STI.getInstrInfo(); |