diff options
| author | Dan Gohman <gohman@apple.com> | 2008-11-18 19:04:29 +0000 |
|---|---|---|
| committer | Dan Gohman <gohman@apple.com> | 2008-11-18 19:04:29 +0000 |
| commit | 0d9d8ae487ae3a5cb1b591d86e9f4929b3c95428 (patch) | |
| tree | 35f1b055a16dee10194af7b9c674b4c5e63c853f /llvm/lib/CodeGen/MachineInstr.cpp | |
| parent | c63831dd6ae38630ec2cdff2807019ac064af39f (diff) | |
| download | bcm5719-llvm-0d9d8ae487ae3a5cb1b591d86e9f4929b3c95428.tar.gz bcm5719-llvm-0d9d8ae487ae3a5cb1b591d86e9f4929b3c95428.zip | |
Make some methods const.
llvm-svn: 59540
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstr.cpp')
| -rw-r--r-- | llvm/lib/CodeGen/MachineInstr.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp index 81fe48e7a67..dfa4629df62 100644 --- a/llvm/lib/CodeGen/MachineInstr.cpp +++ b/llvm/lib/CodeGen/MachineInstr.cpp @@ -695,7 +695,8 @@ void MachineInstr::copyPredicates(const MachineInstr *MI) { /// isSafeToMove - Return true if it is safe to move this instruction. If /// SawStore is set to true, it means that there is a store (or call) between /// the instruction's location and its intended destination. -bool MachineInstr::isSafeToMove(const TargetInstrInfo *TII, bool &SawStore) { +bool MachineInstr::isSafeToMove(const TargetInstrInfo *TII, + bool &SawStore) const { // Ignore stuff that we obviously can't move. if (TID->mayStore() || TID->isCall()) { SawStore = true; @@ -719,7 +720,8 @@ bool MachineInstr::isSafeToMove(const TargetInstrInfo *TII, bool &SawStore) { /// isSafeToReMat - Return true if it's safe to rematerialize the specified /// instruction which defined the specified register instead of copying it. -bool MachineInstr::isSafeToReMat(const TargetInstrInfo *TII, unsigned DstReg) { +bool MachineInstr::isSafeToReMat(const TargetInstrInfo *TII, + unsigned DstReg) const { bool SawStore = false; if (!getDesc().isRematerializable() || !TII->isTriviallyReMaterializable(this) || |

