summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/RegisterCoalescer.cpp
diff options
context:
space:
mode:
authorJakub Staszak <kubastaszak@gmail.com>2012-11-14 20:31:04 +0000
committerJakub Staszak <kubastaszak@gmail.com>2012-11-14 20:31:04 +0000
commit542db4a0bc4648d062d54bb699708c3be7629f80 (patch)
treed399aa9a0bd053d8fe316fdaee75310df833a51e /llvm/lib/CodeGen/RegisterCoalescer.cpp
parent317adfc8b743d275124497bdf1c72b97d055e938 (diff)
downloadbcm5719-llvm-542db4a0bc4648d062d54bb699708c3be7629f80.tar.gz
bcm5719-llvm-542db4a0bc4648d062d54bb699708c3be7629f80.zip
canJoinPhys method doesn't modify CoalescerPair. Make it const.
llvm-svn: 167972
Diffstat (limited to 'llvm/lib/CodeGen/RegisterCoalescer.cpp')
-rw-r--r--llvm/lib/CodeGen/RegisterCoalescer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/RegisterCoalescer.cpp b/llvm/lib/CodeGen/RegisterCoalescer.cpp
index 7151164c42b..7e662e5385b 100644
--- a/llvm/lib/CodeGen/RegisterCoalescer.cpp
+++ b/llvm/lib/CodeGen/RegisterCoalescer.cpp
@@ -178,7 +178,7 @@ namespace {
MachineInstr *CopyMI);
/// canJoinPhys - Return true if a physreg copy should be joined.
- bool canJoinPhys(CoalescerPair &CP);
+ bool canJoinPhys(const CoalescerPair &CP);
/// updateRegDefsUses - Replace all defs and uses of SrcReg to DstReg and
/// update the subregister number if it is not zero. If DstReg is a
@@ -928,7 +928,7 @@ void RegisterCoalescer::updateRegDefsUses(unsigned SrcReg,
}
/// canJoinPhys - Return true if a copy involving a physreg should be joined.
-bool RegisterCoalescer::canJoinPhys(CoalescerPair &CP) {
+bool RegisterCoalescer::canJoinPhys(const CoalescerPair &CP) {
/// Always join simple intervals that are defined by a single copy from a
/// reserved register. This doesn't increase register pressure, so it is
/// always beneficial.
OpenPOWER on IntegriCloud