aboutsummaryrefslogtreecommitdiffstats
path: root/lib/CodeGen
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2008-05-28 22:54:52 +0000
committerBill Wendling <isanbard@gmail.com>2008-05-28 22:54:52 +0000
commitaa25bb1320b4e94d2f90326ab73f2a42e5a4c3b7 (patch)
tree4689ca3c0b6ee971d3aef6ec8536642eefb377a8 /lib/CodeGen
parent023520fc86b25d1db939d9de179118f684948d1c (diff)
downloadexternal_llvm-aa25bb1320b4e94d2f90326ab73f2a42e5a4c3b7.tar.gz
external_llvm-aa25bb1320b4e94d2f90326ab73f2a42e5a4c3b7.tar.bz2
external_llvm-aa25bb1320b4e94d2f90326ab73f2a42e5a4c3b7.zip
Add a flag to indicate that an instruction is as cheap (or cheaper) than a move
instruction to execute. This can be used for transformations (like two-address conversion) to remat an instruction instead of generating a "move" instruction. The idea is to decrease the live ranges and register pressure and all that jazz. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51660 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen')
-rw-r--r--lib/CodeGen/MachineInstr.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/MachineInstr.cpp b/lib/CodeGen/MachineInstr.cpp
index 135718acc7..e008c9a61b 100644
--- a/lib/CodeGen/MachineInstr.cpp
+++ b/lib/CodeGen/MachineInstr.cpp
@@ -639,9 +639,9 @@ void MachineInstr::copyPredicates(const MachineInstr *MI) {
}
}
-/// isSafeToMove - Return true if it is safe to this instruction. If SawStore
-/// true, it means there is a store (or call) between the instruction the
-/// localtion and its intended destination.
+/// isSafeToMove - Return true if it is safe to 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) {
// Ignore stuff that we obviously can't move.
if (TID->mayStore() || TID->isCall()) {