summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-10-27 21:17:45 +0000
committerChris Lattner <sabre@nondot.org>2002-10-27 21:17:45 +0000
commit3baffd73a9db9fcd119d313e95292c06d2dd3b73 (patch)
tree9ab098c7626252b3672ac57fd8e3cf7f734b13a9
parent7d3e5dbf2bf7e990d3bd048817c9755345685467 (diff)
downloadbcm5719-llvm-3baffd73a9db9fcd119d313e95292c06d2dd3b73.tar.gz
bcm5719-llvm-3baffd73a9db9fcd119d313e95292c06d2dd3b73.zip
Add support or other operand types
llvm-svn: 4298
-rw-r--r--llvm/include/llvm/CodeGen/MInstBuilder.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/llvm/include/llvm/CodeGen/MInstBuilder.h b/llvm/include/llvm/CodeGen/MInstBuilder.h
index 6b0ba51fff7..6ff5777503a 100644
--- a/llvm/include/llvm/CodeGen/MInstBuilder.h
+++ b/llvm/include/llvm/CodeGen/MInstBuilder.h
@@ -34,6 +34,26 @@ struct MInstructionBuilder {
return *this;
}
+ /// addSImm - Add a new sign extended immediate operand...
+ ///
+ MInstructionBuilder &addSImm(int Val) {
+ MI->addOperand(Val, MOperand::SignExtImmediate);
+ return *this;
+ }
+
+ /// addZImm - Add a new zero extended immediate operand...
+ ///
+ MInstructionBuilder &addZImm(unsigned Val) {
+ MI->addOperand(Val, MOperand::ZeroExtImmediate);
+ return *this;
+ }
+
+ /// addPCDisp - Add a PC Relative Displacement operand...
+ ///
+ MInstructionBuilder &addPCDisp(int Disp) {
+ MI->addOperand(Disp, MOperand::PCRelativeDisp);
+ return *this;
+ }
};
/// BuildMInst - Builder interface. Specify how to create the initial
OpenPOWER on IntegriCloud