[llvm-commits] CVS: llvm/include/llvm/Target/TargetInstrInfo.h
Evan Cheng
evan.cheng at apple.com
Thu May 17 17:01:28 PDT 2007
Changes in directory llvm/include/llvm/Target:
TargetInstrInfo.h updated: 1.121 -> 1.122
---
Log message:
RemoveBranch() and InsertBranch() now returns number of instructions deleted / inserted.
---
Diffs of the changes: (+8 -4)
TargetInstrInfo.h | 12 ++++++++----
1 files changed, 8 insertions(+), 4 deletions(-)
Index: llvm/include/llvm/Target/TargetInstrInfo.h
diff -u llvm/include/llvm/Target/TargetInstrInfo.h:1.121 llvm/include/llvm/Target/TargetInstrInfo.h:1.122
--- llvm/include/llvm/Target/TargetInstrInfo.h:1.121 Wed May 16 19:10:58 2007
+++ llvm/include/llvm/Target/TargetInstrInfo.h Thu May 17 19:01:09 2007
@@ -350,20 +350,24 @@
}
/// RemoveBranch - Remove the branching code at the end of the specific MBB.
- /// this is only invoked in cases where AnalyzeBranch returns success.
- virtual void RemoveBranch(MachineBasicBlock &MBB) const {
+ /// this is only invoked in cases where AnalyzeBranch returns success. It
+ /// returns the number of instructions that were removed.
+ virtual unsigned RemoveBranch(MachineBasicBlock &MBB) const {
assert(0 && "Target didn't implement TargetInstrInfo::RemoveBranch!");
+ return 0;
}
/// InsertBranch - Insert a branch into the end of the specified
/// MachineBasicBlock. This operands to this method are the same as those
/// returned by AnalyzeBranch. This is invoked in cases where AnalyzeBranch
/// returns success and when an unconditional branch (TBB is non-null, FBB is
- /// null, Cond is empty) needs to be inserted.
- virtual void InsertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
+ /// null, Cond is empty) needs to be inserted. It returns the number of
+ /// instructions inserted.
+ virtual unsigned InsertBranch(MachineBasicBlock &MBB, MachineBasicBlock *TBB,
MachineBasicBlock *FBB,
const std::vector<MachineOperand> &Cond) const {
assert(0 && "Target didn't implement TargetInstrInfo::InsertBranch!");
+ return 0;
}
/// BlockHasNoFallThrough - Return true if the specified block does not
More information about the llvm-commits
mailing list