aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2003-01-15 17:18:22 +0000
committerChris Lattner <sabre@nondot.org>2003-01-15 17:18:22 +0000
commite387de30841a5e106015379b6c47c568cde8b06e (patch)
tree1b94489f9e8581206068e2a4aaa22531242209c7 /include
parent1a57ccdfbfbc9a7ca7d4f81d34db67d48be35a99 (diff)
downloadexternal_llvm-e387de30841a5e106015379b6c47c568cde8b06e.zip
external_llvm-e387de30841a5e106015379b6c47c568cde8b06e.tar.gz
external_llvm-e387de30841a5e106015379b6c47c568cde8b06e.tar.bz2
Add new helper method addRegDef
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5289 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/llvm/CodeGen/MachineInstrBuilder.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/include/llvm/CodeGen/MachineInstrBuilder.h b/include/llvm/CodeGen/MachineInstrBuilder.h
index 2003f86..3d30155 100644
--- a/include/llvm/CodeGen/MachineInstrBuilder.h
+++ b/include/llvm/CodeGen/MachineInstrBuilder.h
@@ -43,13 +43,11 @@ public:
return *this;
}
- /// addClobber - Assert that this MI is going to clobber a specific
- /// register. Useful for instructions that always clobber certain hard regs.
- /// (Same as addReg(RegNo, true) but shorter and more obvious).
+ /// addRegDef - Add an LLVM value that is to be defined as a register... this
+ /// is the same as addReg(V, MOTy::Def).
///
- const MachineInstrBuilder &addClobber(int RegNo) const {
- MI->addRegOperand(RegNo, MOTy::Def);
- return *this;
+ const MachineInstrBuilder &addRegDef(Value *V) const {
+ return addReg(V, MOTy::Def);
}
/// addPCDisp - Add an LLVM value to be treated as a PC relative