LLVM API Documentation
#include <Instructions.h>


Public Member Functions | |
| DECLARE_TRANSPARENT_OPERAND_ACCESSORS (Value) | |
| Provide fast operand accessors. | |
| unsigned | getNumArgOperands () const |
| Value * | getArgOperand (unsigned i) const |
| void | setArgOperand (unsigned i, Value *v) |
| CallingConv::ID | getCallingConv () const |
| void | setCallingConv (CallingConv::ID CC) |
| const AttributeSet & | getAttributes () const |
| void | setAttributes (const AttributeSet &Attrs) |
| void | addAttribute (unsigned i, Attribute::AttrKind attr) |
| addAttribute - adds the attribute to the list of attributes. | |
| void | removeAttribute (unsigned i, Attribute attr) |
| removeAttribute - removes the attribute from the list of attributes. | |
| bool | hasFnAttr (Attribute::AttrKind A) const |
| Determine whether this call has the NoAlias attribute. | |
| bool | paramHasAttr (unsigned i, Attribute::AttrKind A) const |
| Determine whether the call or the callee has the given attributes. | |
| unsigned | getParamAlignment (unsigned i) const |
| Extract the alignment for a call or parameter (0=unknown). | |
| bool | isNoInline () const |
| Return true if the call should not be inlined. | |
| void | setIsNoInline () |
| bool | doesNotAccessMemory () const |
| Determine if the call does not access memory. | |
| void | setDoesNotAccessMemory () |
| bool | onlyReadsMemory () const |
| Determine if the call does not access or only reads memory. | |
| void | setOnlyReadsMemory () |
| bool | doesNotReturn () const |
| Determine if the call cannot return. | |
| void | setDoesNotReturn () |
| bool | doesNotThrow () const |
| Determine if the call cannot unwind. | |
| void | setDoesNotThrow () |
| bool | hasStructRetAttr () const |
| Determine if the call returns a structure through first pointer argument. | |
| bool | hasByValArgument () const |
| Determine if any call argument is an aggregate passed by value. | |
| Function * | getCalledFunction () const |
| const Value * | getCalledValue () const |
| Value * | getCalledValue () |
| void | setCalledFunction (Value *Fn) |
| setCalledFunction - Set the function called. | |
| BasicBlock * | getNormalDest () const |
| BasicBlock * | getUnwindDest () const |
| void | setNormalDest (BasicBlock *B) |
| void | setUnwindDest (BasicBlock *B) |
| LandingPadInst * | getLandingPadInst () const |
| BasicBlock * | getSuccessor (unsigned i) const |
| void | setSuccessor (unsigned idx, BasicBlock *NewSucc) |
| unsigned | getNumSuccessors () const |
Static Public Member Functions | |
| static InvokeInst * | Create (Value *Func, BasicBlock *IfNormal, BasicBlock *IfException, ArrayRef< Value * > Args, const Twine &NameStr="", Instruction *InsertBefore=0) |
| static InvokeInst * | Create (Value *Func, BasicBlock *IfNormal, BasicBlock *IfException, ArrayRef< Value * > Args, const Twine &NameStr, BasicBlock *InsertAtEnd) |
| static bool | classof (const Instruction *I) |
| static bool | classof (const Value *V) |
| Methods for support type inquiry through isa, cast, and dyn_cast: | |
Protected Member Functions | |
| virtual InvokeInst * | clone_impl () const |
InvokeInst - Invoke instruction. The SubclassData field is used to hold the calling convention of the call.
Definition at line 2949 of file Instructions.h.
| void InvokeInst::addAttribute | ( | unsigned | i, |
| Attribute::AttrKind | attr | ||
| ) |
addAttribute - adds the attribute to the list of attributes.
Definition at line 593 of file Instructions.cpp.
References llvm::AttributeSet::addAttribute(), getAttributes(), llvm::Value::getContext(), and setAttributes().
| static bool llvm::InvokeInst::classof | ( | const Instruction * | I | ) | [inline, static] |
Reimplemented from llvm::TerminatorInst.
Definition at line 3128 of file Instructions.h.
References llvm::Instruction::getOpcode().
Methods for support type inquiry through isa, cast, and dyn_cast:
Reimplemented from llvm::TerminatorInst.
Definition at line 3131 of file Instructions.h.
| InvokeInst * InvokeInst::clone_impl | ( | ) | const [protected, virtual] |
Implements llvm::TerminatorInst.
Definition at line 3542 of file Instructions.cpp.
References llvm::User::getNumOperands().
| static InvokeInst* llvm::InvokeInst::Create | ( | Value * | Func, |
| BasicBlock * | IfNormal, | ||
| BasicBlock * | IfException, | ||
| ArrayRef< Value * > | Args, | ||
| const Twine & | NameStr = "", |
||
| Instruction * | InsertBefore = 0 |
||
| ) | [inline, static] |
Definition at line 2971 of file Instructions.h.
References llvm::ArrayRef< T >::size().
Referenced by llvm::IRBuilder< true, TargetFolder >::CreateInvoke(), llvm::IRBuilder< true, TargetFolder >::CreateInvoke3(), HandleCallsInBlockInlinedThroughInvoke(), and llvm::InstCombiner::visitAllocSite().
| static InvokeInst* llvm::InvokeInst::Create | ( | Value * | Func, |
| BasicBlock * | IfNormal, | ||
| BasicBlock * | IfException, | ||
| ArrayRef< Value * > | Args, | ||
| const Twine & | NameStr, | ||
| BasicBlock * | InsertAtEnd | ||
| ) | [inline, static] |
Definition at line 2979 of file Instructions.h.
References llvm::ArrayRef< T >::size().
| llvm::InvokeInst::DECLARE_TRANSPARENT_OPERAND_ACCESSORS | ( | Value | ) |
Provide fast operand accessors.
| bool llvm::InvokeInst::doesNotAccessMemory | ( | ) | const [inline] |
Determine if the call does not access memory.
Definition at line 3041 of file Instructions.h.
References llvm::Attribute::ReadNone.
| bool llvm::InvokeInst::doesNotReturn | ( | ) | const [inline] |
Determine if the call cannot return.
Definition at line 3057 of file Instructions.h.
References llvm::Attribute::NoReturn.
| bool llvm::InvokeInst::doesNotThrow | ( | ) | const [inline] |
Determine if the call cannot unwind.
Definition at line 3063 of file Instructions.h.
References llvm::Attribute::NoUnwind.
getArgOperand/setArgOperand - Return/set the i-th invoke argument.
Definition at line 2997 of file Instructions.h.
| const AttributeSet& llvm::InvokeInst::getAttributes | ( | ) | const [inline] |
getAttributes - Return the parameter attributes for this invoke.
Definition at line 3011 of file Instructions.h.
Referenced by addAttribute(), changeToCall(), removeAttribute(), and WriteInstruction().
| Function* llvm::InvokeInst::getCalledFunction | ( | ) | const [inline] |
getCalledFunction - Return the function called, or null if this is an indirect function invocation.
Definition at line 3083 of file Instructions.h.
References llvm::dyn_cast().
Referenced by hasFnAttr(), and paramHasAttr().
| const Value* llvm::InvokeInst::getCalledValue | ( | ) | const [inline] |
getCalledValue - Get a pointer to the function that is invoked by this instruction
Definition at line 3089 of file Instructions.h.
Referenced by changeToCall(), and WriteInstruction().
| Value* llvm::InvokeInst::getCalledValue | ( | ) | [inline] |
Definition at line 3090 of file Instructions.h.
| CallingConv::ID llvm::InvokeInst::getCallingConv | ( | ) | const [inline] |
getCallingConv/setCallingConv - Get or set the calling convention of this function call.
Definition at line 3002 of file Instructions.h.
Referenced by changeToCall(), and WriteInstruction().
| LandingPadInst * InvokeInst::getLandingPadInst | ( | ) | const |
getLandingPadInst - Get the landingpad instruction from the landing pad block (the unwind destination).
Definition at line 607 of file Instructions.cpp.
References llvm::BasicBlock::getFirstNonPHI(), and getUnwindDest().
Referenced by HandleInlinedInvoke().
| BasicBlock* llvm::InvokeInst::getNormalDest | ( | ) | const [inline] |
Definition at line 3098 of file Instructions.h.
Referenced by changeToCall(), llvm::DemoteRegToStack(), llvm::DominatorTree::dominates(), llvm::InlineFunction(), and WriteInstruction().
| unsigned llvm::InvokeInst::getNumArgOperands | ( | ) | const [inline] |
getNumArgOperands - Return the number of invoke arguments.
Definition at line 2993 of file Instructions.h.
| unsigned llvm::InvokeInst::getNumSuccessors | ( | ) | const [inline] |
getNumSuccessors - Return the number of successors that this terminator has.
Reimplemented from llvm::TerminatorInst.
Definition at line 3125 of file Instructions.h.
Extract the alignment for a call or parameter (0=unknown).
Definition at line 3030 of file Instructions.h.
References llvm::AttributeSet::getParamAlignment().
| BasicBlock* llvm::InvokeInst::getSuccessor | ( | unsigned | idx | ) | const [inline] |
getSuccessor - Return the specified successor.
Reimplemented from llvm::TerminatorInst.
Definition at line 3115 of file Instructions.h.
| BasicBlock* llvm::InvokeInst::getUnwindDest | ( | ) | const [inline] |
Definition at line 3101 of file Instructions.h.
Referenced by changeToCall(), getLandingPadInst(), HandleInlinedInvoke(), llvm::InlineFunction(), and WriteInstruction().
| bool llvm::InvokeInst::hasByValArgument | ( | ) | const [inline] |
Determine if any call argument is an aggregate passed by value.
Definition at line 3076 of file Instructions.h.
References llvm::Attribute::ByVal, and llvm::AttributeSet::hasAttrSomewhere().
| bool InvokeInst::hasFnAttr | ( | Attribute::AttrKind | A | ) | const |
Determine whether this call has the NoAlias attribute.
Definition at line 577 of file Instructions.cpp.
References F(), llvm::AttributeSet::FunctionIndex, getCalledFunction(), and llvm::AttributeSet::hasAttribute().
| bool llvm::InvokeInst::hasStructRetAttr | ( | ) | const [inline] |
Determine if the call returns a structure through first pointer argument.
Definition at line 3070 of file Instructions.h.
References llvm::Attribute::StructRet.
| bool llvm::InvokeInst::isNoInline | ( | ) | const [inline] |
Return true if the call should not be inlined.
Definition at line 3035 of file Instructions.h.
References llvm::Attribute::NoInline.
| bool llvm::InvokeInst::onlyReadsMemory | ( | ) | const [inline] |
Determine if the call does not access or only reads memory.
Definition at line 3049 of file Instructions.h.
References llvm::Attribute::ReadOnly.
| bool InvokeInst::paramHasAttr | ( | unsigned | i, |
| Attribute::AttrKind | A | ||
| ) | const |
Determine whether the call or the callee has the given attributes.
Definition at line 585 of file Instructions.cpp.
References F(), getCalledFunction(), and llvm::AttributeSet::hasAttribute().
removeAttribute - removes the attribute from the list of attributes.
Definition at line 599 of file Instructions.cpp.
References getAttributes(), llvm::Value::getContext(), llvm::AttributeSet::removeAttributes(), and setAttributes().
Definition at line 2998 of file Instructions.h.
| void llvm::InvokeInst::setAttributes | ( | const AttributeSet & | Attrs | ) | [inline] |
setAttributes - Set the parameter attributes for this invoke.
Definition at line 3015 of file Instructions.h.
Referenced by addAttribute(), and removeAttribute().
| void llvm::InvokeInst::setCalledFunction | ( | Value * | Fn | ) | [inline] |
setCalledFunction - Set the function called.
Definition at line 3093 of file Instructions.h.
| void llvm::InvokeInst::setCallingConv | ( | CallingConv::ID | CC | ) | [inline] |
Definition at line 3005 of file Instructions.h.
| void llvm::InvokeInst::setDoesNotAccessMemory | ( | ) | [inline] |
Definition at line 3044 of file Instructions.h.
References llvm::AttributeSet::FunctionIndex, and llvm::Attribute::ReadNone.
| void llvm::InvokeInst::setDoesNotReturn | ( | ) | [inline] |
Definition at line 3058 of file Instructions.h.
References llvm::AttributeSet::FunctionIndex, and llvm::Attribute::NoReturn.
| void llvm::InvokeInst::setDoesNotThrow | ( | ) | [inline] |
Definition at line 3064 of file Instructions.h.
References llvm::AttributeSet::FunctionIndex, and llvm::Attribute::NoUnwind.
| void llvm::InvokeInst::setIsNoInline | ( | ) | [inline] |
Definition at line 3036 of file Instructions.h.
References llvm::AttributeSet::FunctionIndex, and llvm::Attribute::NoInline.
| void llvm::InvokeInst::setNormalDest | ( | BasicBlock * | B | ) | [inline] |
Definition at line 3104 of file Instructions.h.
| void llvm::InvokeInst::setOnlyReadsMemory | ( | ) | [inline] |
Definition at line 3052 of file Instructions.h.
References llvm::AttributeSet::FunctionIndex, and llvm::Attribute::ReadOnly.
| void llvm::InvokeInst::setSuccessor | ( | unsigned | idx, |
| BasicBlock * | B | ||
| ) | [inline] |
setSuccessor - Update the specified successor to point at the provided block.
Reimplemented from llvm::TerminatorInst.
Definition at line 3120 of file Instructions.h.
| void llvm::InvokeInst::setUnwindDest | ( | BasicBlock * | B | ) | [inline] |
Definition at line 3107 of file Instructions.h.