Move some functionality for adding flags to MachineInstr's into methods on MachineInstr rather than LiveVariables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46295 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson
2008-01-24 01:10:07 +00:00
parent 3ae054385c
commit b487e7215c
5 changed files with 126 additions and 130 deletions

View File

@@ -21,6 +21,7 @@
namespace llvm {
class TargetInstrDesc;
class MRegisterInfo;
template <typename T> struct ilist_traits;
template <typename T> struct ilist;
@@ -144,6 +145,24 @@ public:
/// copyPredicates - Copies predicate operand(s) from MI.
void copyPredicates(const MachineInstr *MI);
/// addRegisterKilled - We have determined MI kills a register. Look for the
/// operand that uses it and mark it as IsKill. If AddIfNotFound is true,
/// add a implicit operand if it's not found. Returns true if the operand
/// exists / is added.
bool addRegisterKilled(unsigned IncomingReg, const MRegisterInfo *RegInfo,
bool AddIfNotFound = false);
/// addRegisterDead - We have determined MI defined a register without a use.
/// Look for the operand that defines it and mark it as IsDead. If
/// AddIfNotFound is true, add a implicit operand if it's not found. Returns
/// true if the operand exists / is added.
bool addRegisterDead(unsigned IncomingReg, const MRegisterInfo *RegInfo,
bool AddIfNotFound = false);
/// copyKillDeadInfo - copies killed/dead information from one instr to another
void copyKillDeadInfo(MachineInstr *OldMI,
const MRegisterInfo *RegInfo);
//
// Debugging support
//