LLVM 19.0.0git
Classes | Public Member Functions | Protected Attributes | List of all members
llvm::IRBuilderBase Class Reference

Common base class shared among various IRBuilders. More...

#include "llvm/IR/IRBuilder.h"

Inheritance diagram for llvm::IRBuilderBase:
Inheritance graph
[legend]

Classes

class  FastMathFlagGuard
 
class  InsertPoint
 InsertPoint - A saved insertion point. More...
 
class  InsertPointGuard
 
class  OperandBundlesGuard
 

Public Member Functions

 IRBuilderBase (LLVMContext &context, const IRBuilderFolder &Folder, const IRBuilderDefaultInserter &Inserter, MDNode *FPMathTag, ArrayRef< OperandBundleDef > OpBundles)
 
template<typename InstTy >
InstTy * Insert (InstTy *I, const Twine &Name="") const
 Insert and return the specified instruction.
 
ConstantInsert (Constant *C, const Twine &="") const
 No-op overload to handle constants.
 
ValueInsert (Value *V, const Twine &Name="") const
 
void ClearInsertionPoint ()
 Clear the insertion point: created instructions will not be inserted into a block.
 
BasicBlockGetInsertBlock () const
 
BasicBlock::iterator GetInsertPoint () const
 
LLVMContextgetContext () const
 
void SetInsertPoint (BasicBlock *TheBB)
 This specifies that created instructions should be appended to the end of the specified block.
 
void SetInsertPoint (Instruction *I)
 This specifies that created instructions should be inserted before the specified instruction.
 
void SetInsertPoint (BasicBlock *TheBB, BasicBlock::iterator IP)
 This specifies that created instructions should be inserted at the specified point.
 
void SetInsertPoint (BasicBlock::iterator IP)
 This specifies that created instructions should be inserted at the specified point, but also requires that IP is dereferencable.
 
void SetInsertPointPastAllocas (Function *F)
 This specifies that created instructions should inserted at the beginning end of the specified function, but after already existing static alloca instructions that are at the start.
 
void SetCurrentDebugLocation (DebugLoc L)
 Set location information used by debugging information.
 
void CollectMetadataToCopy (Instruction *Src, ArrayRef< unsigned > MetadataKinds)
 Collect metadata with IDs MetadataKinds from Src which should be added to all created instructions.
 
DebugLoc getCurrentDebugLocation () const
 Get location information used by debugging information.
 
void SetInstDebugLocation (Instruction *I) const
 If this builder has a current debug location, set it on the specified instruction.
 
void AddMetadataToInst (Instruction *I) const
 Add all entries in MetadataToCopy to I.
 
TypegetCurrentFunctionReturnType () const
 Get the return type of the current function that we're emitting into.
 
InsertPoint saveIP () const
 Returns the current insert point.
 
InsertPoint saveAndClearIP ()
 Returns the current insert point, clearing it in the process.
 
void restoreIP (InsertPoint IP)
 Sets the current insert point to a previously-saved location.
 
MDNodegetDefaultFPMathTag () const
 Get the floating point math metadata being used.
 
FastMathFlags getFastMathFlags () const
 Get the flags to be applied to created floating point ops.
 
FastMathFlagsgetFastMathFlags ()
 
void clearFastMathFlags ()
 Clear the fast-math flags.
 
void setDefaultFPMathTag (MDNode *FPMathTag)
 Set the floating point math metadata to be used.
 
void setFastMathFlags (FastMathFlags NewFMF)
 Set the fast-math flags to be used with generated fp-math operators.
 
void setIsFPConstrained (bool IsCon)
 Enable/Disable use of constrained floating point math.
 
bool getIsFPConstrained ()
 Query for the use of constrained floating point math.
 
void setDefaultConstrainedExcept (fp::ExceptionBehavior NewExcept)
 Set the exception handling to be used with constrained floating point.
 
void setDefaultConstrainedRounding (RoundingMode NewRounding)
 Set the rounding mode handling to be used with constrained floating point.
 
fp::ExceptionBehavior getDefaultConstrainedExcept ()
 Get the exception handling used with constrained floating point.
 
RoundingMode getDefaultConstrainedRounding ()
 Get the rounding mode handling used with constrained floating point.
 
void setConstrainedFPFunctionAttr ()
 
void setConstrainedFPCallAttr (CallBase *I)
 
void setDefaultOperandBundles (ArrayRef< OperandBundleDef > OpBundles)
 
GlobalVariableCreateGlobalString (StringRef Str, const Twine &Name="", unsigned AddressSpace=0, Module *M=nullptr)
 Make a new global variable with initializer type i8*.
 
ConstantIntgetInt1 (bool V)
 Get a constant value representing either true or false.
 
ConstantIntgetTrue ()
 Get the constant value for i1 true.
 
ConstantIntgetFalse ()
 Get the constant value for i1 false.
 
ConstantIntgetInt8 (uint8_t C)
 Get a constant 8-bit value.
 
ConstantIntgetInt16 (uint16_t C)
 Get a constant 16-bit value.
 
ConstantIntgetInt32 (uint32_t C)
 Get a constant 32-bit value.
 
ConstantIntgetInt64 (uint64_t C)
 Get a constant 64-bit value.
 
ConstantIntgetIntN (unsigned N, uint64_t C)
 Get a constant N-bit value, zero extended or truncated from a 64-bit value.
 
ConstantIntgetInt (const APInt &AI)
 Get a constant integer value.
 
IntegerTypegetInt1Ty ()
 Fetch the type representing a single bit.
 
IntegerTypegetInt8Ty ()
 Fetch the type representing an 8-bit integer.
 
IntegerTypegetInt16Ty ()
 Fetch the type representing a 16-bit integer.
 
IntegerTypegetInt32Ty ()
 Fetch the type representing a 32-bit integer.
 
IntegerTypegetInt64Ty ()
 Fetch the type representing a 64-bit integer.
 
IntegerTypegetInt128Ty ()
 Fetch the type representing a 128-bit integer.
 
IntegerTypegetIntNTy (unsigned N)
 Fetch the type representing an N-bit integer.
 
TypegetHalfTy ()
 Fetch the type representing a 16-bit floating point value.
 
TypegetBFloatTy ()
 Fetch the type representing a 16-bit brain floating point value.
 
TypegetFloatTy ()
 Fetch the type representing a 32-bit floating point value.
 
TypegetDoubleTy ()
 Fetch the type representing a 64-bit floating point value.
 
TypegetVoidTy ()
 Fetch the type representing void.
 
PointerTypegetPtrTy (unsigned AddrSpace=0)
 Fetch the type representing a pointer.
 
IntegerTypegetIntPtrTy (const DataLayout &DL, unsigned AddrSpace=0)
 Fetch the type of an integer with size at least as big as that of a pointer in the given address space.
 
IntegerTypegetIndexTy (const DataLayout &DL, unsigned AddrSpace)
 Fetch the type of an integer that should be used to index GEP operations within AddressSpace.
 
CallInstCreateMemSet (Value *Ptr, Value *Val, uint64_t Size, MaybeAlign Align, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 Create and insert a memset to the specified pointer and the specified value.
 
CallInstCreateMemSet (Value *Ptr, Value *Val, Value *Size, MaybeAlign Align, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateMemSetInline (Value *Dst, MaybeAlign DstAlign, Value *Val, Value *Size, bool IsVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateElementUnorderedAtomicMemSet (Value *Ptr, Value *Val, uint64_t Size, Align Alignment, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 Create and insert an element unordered-atomic memset of the region of memory starting at the given pointer to the given value.
 
CallInstCreateMalloc (Type *IntPtrTy, Type *AllocTy, Value *AllocSize, Value *ArraySize, ArrayRef< OperandBundleDef > OpB, Function *MallocF=nullptr, const Twine &Name="")
 
CallInstCreateMalloc (Type *IntPtrTy, Type *AllocTy, Value *AllocSize, Value *ArraySize, Function *MallocF=nullptr, const Twine &Name="")
 CreateMalloc - Generate the IR for a call to malloc:
 
CallInstCreateFree (Value *Source, ArrayRef< OperandBundleDef > Bundles=std::nullopt)
 Generate the IR for a call to the builtin free function.
 
CallInstCreateElementUnorderedAtomicMemSet (Value *Ptr, Value *Val, Value *Size, Align Alignment, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateMemCpy (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, uint64_t Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 Create and insert a memcpy between the specified pointers.
 
CallInstCreateMemTransferInst (Intrinsic::ID IntrID, Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateMemCpy (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateMemCpyInline (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateElementUnorderedAtomicMemCpy (Value *Dst, Align DstAlign, Value *Src, Align SrcAlign, Value *Size, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 Create and insert an element unordered-atomic memcpy between the specified pointers.
 
CallInstCreateMemMove (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, uint64_t Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateMemMove (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 
CallInstCreateElementUnorderedAtomicMemMove (Value *Dst, Align DstAlign, Value *Src, Align SrcAlign, Value *Size, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr)
 Create and insert an element unordered-atomic memmove between the specified pointers.
 
CallInstCreateFAddReduce (Value *Acc, Value *Src)
 Create a sequential vector fadd reduction intrinsic of the source vector.
 
CallInstCreateFMulReduce (Value *Acc, Value *Src)
 Create a sequential vector fmul reduction intrinsic of the source vector.
 
CallInstCreateAddReduce (Value *Src)
 Create a vector int add reduction intrinsic of the source vector.
 
CallInstCreateMulReduce (Value *Src)
 Create a vector int mul reduction intrinsic of the source vector.
 
CallInstCreateAndReduce (Value *Src)
 Create a vector int AND reduction intrinsic of the source vector.
 
CallInstCreateOrReduce (Value *Src)
 Create a vector int OR reduction intrinsic of the source vector.
 
CallInstCreateXorReduce (Value *Src)
 Create a vector int XOR reduction intrinsic of the source vector.
 
CallInstCreateIntMaxReduce (Value *Src, bool IsSigned=false)
 Create a vector integer max reduction intrinsic of the source vector.
 
CallInstCreateIntMinReduce (Value *Src, bool IsSigned=false)
 Create a vector integer min reduction intrinsic of the source vector.
 
CallInstCreateFPMaxReduce (Value *Src)
 Create a vector float max reduction intrinsic of the source vector.
 
CallInstCreateFPMinReduce (Value *Src)
 Create a vector float min reduction intrinsic of the source vector.
 
CallInstCreateFPMaximumReduce (Value *Src)
 Create a vector float maximum reduction intrinsic of the source vector.
 
CallInstCreateFPMinimumReduce (Value *Src)
 Create a vector float minimum reduction intrinsic of the source vector.
 
CallInstCreateLifetimeStart (Value *Ptr, ConstantInt *Size=nullptr)
 Create a lifetime.start intrinsic.
 
CallInstCreateLifetimeEnd (Value *Ptr, ConstantInt *Size=nullptr)
 Create a lifetime.end intrinsic.
 
CallInstCreateInvariantStart (Value *Ptr, ConstantInt *Size=nullptr)
 Create a call to invariant.start intrinsic.
 
CallInstCreateThreadLocalAddress (Value *Ptr)
 Create a call to llvm.threadlocal.address intrinsic.
 
CallInstCreateMaskedLoad (Type *Ty, Value *Ptr, Align Alignment, Value *Mask, Value *PassThru=nullptr, const Twine &Name="")
 Create a call to Masked Load intrinsic.
 
CallInstCreateMaskedStore (Value *Val, Value *Ptr, Align Alignment, Value *Mask)
 Create a call to Masked Store intrinsic.
 
CallInstCreateMaskedGather (Type *Ty, Value *Ptrs, Align Alignment, Value *Mask=nullptr, Value *PassThru=nullptr, const Twine &Name="")
 Create a call to Masked Gather intrinsic.
 
CallInstCreateMaskedScatter (Value *Val, Value *Ptrs, Align Alignment, Value *Mask=nullptr)
 Create a call to Masked Scatter intrinsic.
 
CallInstCreateMaskedExpandLoad (Type *Ty, Value *Ptr, Value *Mask=nullptr, Value *PassThru=nullptr, const Twine &Name="")
 Create a call to Masked Expand Load intrinsic.
 
CallInstCreateMaskedCompressStore (Value *Val, Value *Ptr, Value *Mask=nullptr)
 Create a call to Masked Compress Store intrinsic.
 
ValuegetAllOnesMask (ElementCount NumElts)
 Return an all true boolean vector (mask) with NumElts lanes.
 
CallInstCreateAssumption (Value *Cond, ArrayRef< OperandBundleDef > OpBundles=std::nullopt)
 Create an assume intrinsic call that allows the optimizer to assume that the provided condition will be true.
 
InstructionCreateNoAliasScopeDeclaration (Value *Scope)
 Create a llvm.experimental.noalias.scope.decl intrinsic call.
 
InstructionCreateNoAliasScopeDeclaration (MDNode *ScopeTag)
 
CallInstCreateGCStatepointCall (uint64_t ID, uint32_t NumPatchBytes, FunctionCallee ActualCallee, ArrayRef< Value * > CallArgs, std::optional< ArrayRef< Value * > > DeoptArgs, ArrayRef< Value * > GCArgs, const Twine &Name="")
 Create a call to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.
 
CallInstCreateGCStatepointCall (uint64_t ID, uint32_t NumPatchBytes, FunctionCallee ActualCallee, uint32_t Flags, ArrayRef< Value * > CallArgs, std::optional< ArrayRef< Use > > TransitionArgs, std::optional< ArrayRef< Use > > DeoptArgs, ArrayRef< Value * > GCArgs, const Twine &Name="")
 Create a call to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.
 
CallInstCreateGCStatepointCall (uint64_t ID, uint32_t NumPatchBytes, FunctionCallee ActualCallee, ArrayRef< Use > CallArgs, std::optional< ArrayRef< Value * > > DeoptArgs, ArrayRef< Value * > GCArgs, const Twine &Name="")
 Conveninence function for the common case when CallArgs are filled in using ArrayRef(CS.arg_begin(), CS.arg_end()); Use needs to be .get()'ed to get the Value pointer.
 
InvokeInstCreateGCStatepointInvoke (uint64_t ID, uint32_t NumPatchBytes, FunctionCallee ActualInvokee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > InvokeArgs, std::optional< ArrayRef< Value * > > DeoptArgs, ArrayRef< Value * > GCArgs, const Twine &Name="")
 Create an invoke to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.
 
InvokeInstCreateGCStatepointInvoke (uint64_t ID, uint32_t NumPatchBytes, FunctionCallee ActualInvokee, BasicBlock *NormalDest, BasicBlock *UnwindDest, uint32_t Flags, ArrayRef< Value * > InvokeArgs, std::optional< ArrayRef< Use > > TransitionArgs, std::optional< ArrayRef< Use > > DeoptArgs, ArrayRef< Value * > GCArgs, const Twine &Name="")
 Create an invoke to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.
 
InvokeInstCreateGCStatepointInvoke (uint64_t ID, uint32_t NumPatchBytes, FunctionCallee ActualInvokee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Use > InvokeArgs, std::optional< ArrayRef< Value * > > DeoptArgs, ArrayRef< Value * > GCArgs, const Twine &Name="")
 
CallInstCreateGCResult (Instruction *Statepoint, Type *ResultType, const Twine &Name="")
 Create a call to the experimental.gc.result intrinsic to extract the result from a call wrapped in a statepoint.
 
CallInstCreateGCRelocate (Instruction *Statepoint, int BaseOffset, int DerivedOffset, Type *ResultType, const Twine &Name="")
 Create a call to the experimental.gc.relocate intrinsics to project the relocated value of one pointer from the statepoint.
 
CallInstCreateGCGetPointerBase (Value *DerivedPtr, const Twine &Name="")
 Create a call to the experimental.gc.pointer.base intrinsic to get the base pointer for the specified derived pointer.
 
CallInstCreateGCGetPointerOffset (Value *DerivedPtr, const Twine &Name="")
 Create a call to the experimental.gc.get.pointer.offset intrinsic to get the offset of the specified derived pointer from its base.
 
ValueCreateVScale (Constant *Scaling, const Twine &Name="")
 Create a call to llvm.vscale, multiplied by Scaling.
 
ValueCreateElementCount (Type *DstType, ElementCount EC)
 Create an expression which evaluates to the number of elements in EC at runtime.
 
ValueCreateTypeSize (Type *DstType, TypeSize Size)
 Create an expression which evaluates to the number of units in Size at runtime.
 
ValueCreateStepVector (Type *DstType, const Twine &Name="")
 Creates a vector of type DstType with the linear sequence <0, 1, ...>
 
CallInstCreateUnaryIntrinsic (Intrinsic::ID ID, Value *V, Instruction *FMFSource=nullptr, const Twine &Name="")
 Create a call to intrinsic ID with 1 operand which is mangled on its type.
 
CallInstCreateBinaryIntrinsic (Intrinsic::ID ID, Value *LHS, Value *RHS, Instruction *FMFSource=nullptr, const Twine &Name="")
 Create a call to intrinsic ID with 2 operands which is mangled on the first type.
 
CallInstCreateIntrinsic (Intrinsic::ID ID, ArrayRef< Type * > Types, ArrayRef< Value * > Args, Instruction *FMFSource=nullptr, const Twine &Name="")
 Create a call to intrinsic ID with Args, mangled using Types.
 
CallInstCreateIntrinsic (Type *RetTy, Intrinsic::ID ID, ArrayRef< Value * > Args, Instruction *FMFSource=nullptr, const Twine &Name="")
 Create a call to intrinsic ID with RetTy and Args.
 
CallInstCreateMinNum (Value *LHS, Value *RHS, const Twine &Name="")
 Create call to the minnum intrinsic.
 
CallInstCreateMaxNum (Value *LHS, Value *RHS, const Twine &Name="")
 Create call to the maxnum intrinsic.
 
CallInstCreateMinimum (Value *LHS, Value *RHS, const Twine &Name="")
 Create call to the minimum intrinsic.
 
CallInstCreateMaximum (Value *LHS, Value *RHS, const Twine &Name="")
 Create call to the maximum intrinsic.
 
CallInstCreateCopySign (Value *LHS, Value *RHS, Instruction *FMFSource=nullptr, const Twine &Name="")
 Create call to the copysign intrinsic.
 
CallInstCreateArithmeticFence (Value *Val, Type *DstType, const Twine &Name="")
 Create a call to the arithmetic_fence intrinsic.
 
CallInstCreateExtractVector (Type *DstType, Value *SrcVec, Value *Idx, const Twine &Name="")
 Create a call to the vector.extract intrinsic.
 
CallInstCreateInsertVector (Type *DstType, Value *SrcVec, Value *SubVec, Value *Idx, const Twine &Name="")
 Create a call to the vector.insert intrinsic.
 
CallInstCreateStackSave (const Twine &Name="")
 Create a call to llvm.stacksave.
 
CallInstCreateStackRestore (Value *Ptr, const Twine &Name="")
 Create a call to llvm.stackrestore.
 
ReturnInstCreateRetVoid ()
 Create a 'ret void' instruction.
 
ReturnInstCreateRet (Value *V)
 Create a 'ret <val>' instruction.
 
ReturnInstCreateAggregateRet (Value *const *retVals, unsigned N)
 Create a sequence of N insertvalue instructions, with one Value from the retVals array each, that build a aggregate return value one value at a time, and a ret instruction to return the resulting aggregate value.
 
BranchInstCreateBr (BasicBlock *Dest)
 Create an unconditional 'br label X' instruction.
 
BranchInstCreateCondBr (Value *Cond, BasicBlock *True, BasicBlock *False, MDNode *BranchWeights=nullptr, MDNode *Unpredictable=nullptr)
 Create a conditional 'br Cond, TrueDest, FalseDest' instruction.
 
BranchInstCreateCondBr (Value *Cond, BasicBlock *True, BasicBlock *False, Instruction *MDSrc)
 Create a conditional 'br Cond, TrueDest, FalseDest' instruction.
 
SwitchInstCreateSwitch (Value *V, BasicBlock *Dest, unsigned NumCases=10, MDNode *BranchWeights=nullptr, MDNode *Unpredictable=nullptr)
 Create a switch instruction with the specified value, default dest, and with a hint for the number of cases that will be added (for efficient allocation).
 
IndirectBrInstCreateIndirectBr (Value *Addr, unsigned NumDests=10)
 Create an indirect branch instruction with the specified address operand, with an optional hint for the number of destinations that will be added (for efficient allocation).
 
InvokeInstCreateInvoke (FunctionType *Ty, Value *Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="")
 Create an invoke instruction.
 
InvokeInstCreateInvoke (FunctionType *Ty, Value *Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="")
 
InvokeInstCreateInvoke (FunctionCallee Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="")
 
InvokeInstCreateInvoke (FunctionCallee Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="")
 
CallBrInstCreateCallBr (FunctionType *Ty, Value *Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="")
 Create a callbr instruction.
 
CallBrInstCreateCallBr (FunctionType *Ty, Value *Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="")
 
CallBrInstCreateCallBr (FunctionCallee Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="")
 
CallBrInstCreateCallBr (FunctionCallee Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="")
 
ResumeInstCreateResume (Value *Exn)
 
CleanupReturnInstCreateCleanupRet (CleanupPadInst *CleanupPad, BasicBlock *UnwindBB=nullptr)
 
CatchSwitchInstCreateCatchSwitch (Value *ParentPad, BasicBlock *UnwindBB, unsigned NumHandlers, const Twine &Name="")
 
CatchPadInstCreateCatchPad (Value *ParentPad, ArrayRef< Value * > Args, const Twine &Name="")
 
CleanupPadInstCreateCleanupPad (Value *ParentPad, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="")
 
CatchReturnInstCreateCatchRet (CatchPadInst *CatchPad, BasicBlock *BB)
 
UnreachableInstCreateUnreachable ()
 
ValueCreateAdd (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateNSWAdd (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateNUWAdd (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateSub (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateNSWSub (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateNUWSub (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateMul (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateNSWMul (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateNUWMul (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateUDiv (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateExactUDiv (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateSDiv (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateExactSDiv (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateURem (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateSRem (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateShl (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateShl (Value *LHS, const APInt &RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateShl (Value *LHS, uint64_t RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateLShr (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateLShr (Value *LHS, const APInt &RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateLShr (Value *LHS, uint64_t RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateAShr (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateAShr (Value *LHS, const APInt &RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateAShr (Value *LHS, uint64_t RHS, const Twine &Name="", bool isExact=false)
 
ValueCreateAnd (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateAnd (Value *LHS, const APInt &RHS, const Twine &Name="")
 
ValueCreateAnd (Value *LHS, uint64_t RHS, const Twine &Name="")
 
ValueCreateAnd (ArrayRef< Value * > Ops)
 
ValueCreateOr (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateOr (Value *LHS, const APInt &RHS, const Twine &Name="")
 
ValueCreateOr (Value *LHS, uint64_t RHS, const Twine &Name="")
 
ValueCreateOr (ArrayRef< Value * > Ops)
 
ValueCreateXor (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateXor (Value *LHS, const APInt &RHS, const Twine &Name="")
 
ValueCreateXor (Value *LHS, uint64_t RHS, const Twine &Name="")
 
ValueCreateFAdd (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr)
 
ValueCreateFAddFMF (Value *L, Value *R, Instruction *FMFSource, const Twine &Name="")
 Copy fast-math-flags from an instruction rather than using the builder's default FMF.
 
ValueCreateFSub (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr)
 
ValueCreateFSubFMF (Value *L, Value *R, Instruction *FMFSource, const Twine &Name="")
 Copy fast-math-flags from an instruction rather than using the builder's default FMF.
 
ValueCreateFMul (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr)
 
ValueCreateFMulFMF (Value *L, Value *R, Instruction *FMFSource, const Twine &Name="")
 Copy fast-math-flags from an instruction rather than using the builder's default FMF.
 
ValueCreateFDiv (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr)
 
ValueCreateFDivFMF (Value *L, Value *R, Instruction *FMFSource, const Twine &Name="")
 Copy fast-math-flags from an instruction rather than using the builder's default FMF.
 
ValueCreateFRem (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr)
 
ValueCreateFRemFMF (Value *L, Value *R, Instruction *FMFSource, const Twine &Name="")
 Copy fast-math-flags from an instruction rather than using the builder's default FMF.
 
ValueCreateBinOp (Instruction::BinaryOps Opc, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateLogicalAnd (Value *Cond1, Value *Cond2, const Twine &Name="")
 
ValueCreateLogicalOr (Value *Cond1, Value *Cond2, const Twine &Name="")
 
ValueCreateLogicalOp (Instruction::BinaryOps Opc, Value *Cond1, Value *Cond2, const Twine &Name="")
 
ValueCreateLogicalOr (ArrayRef< Value * > Ops)
 
CallInstCreateConstrainedFPBinOp (Intrinsic::ID ID, Value *L, Value *R, Instruction *FMFSource=nullptr, const Twine &Name="", MDNode *FPMathTag=nullptr, std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt)
 
CallInstCreateConstrainedFPUnroundedBinOp (Intrinsic::ID ID, Value *L, Value *R, Instruction *FMFSource=nullptr, const Twine &Name="", MDNode *FPMathTag=nullptr, std::optional< fp::ExceptionBehavior > Except=std::nullopt)
 
ValueCreateNeg (Value *V, const Twine &Name="", bool HasNUW=false, bool HasNSW=false)
 
ValueCreateNSWNeg (Value *V, const Twine &Name="")
 
ValueCreateNUWNeg (Value *V, const Twine &Name="")
 
ValueCreateFNeg (Value *V, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFNegFMF (Value *V, Instruction *FMFSource, const Twine &Name="")
 Copy fast-math-flags from an instruction rather than using the builder's default FMF.
 
ValueCreateNot (Value *V, const Twine &Name="")
 
ValueCreateUnOp (Instruction::UnaryOps Opc, Value *V, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateNAryOp (unsigned Opc, ArrayRef< Value * > Ops, const Twine &Name="", MDNode *FPMathTag=nullptr)
 Create either a UnaryOperator or BinaryOperator depending on Opc.
 
AllocaInstCreateAlloca (Type *Ty, unsigned AddrSpace, Value *ArraySize=nullptr, const Twine &Name="")
 
AllocaInstCreateAlloca (Type *Ty, Value *ArraySize=nullptr, const Twine &Name="")
 
LoadInstCreateLoad (Type *Ty, Value *Ptr, const char *Name)
 Provided to resolve 'CreateLoad(Ty, Ptr, "...")' correctly, instead of converting the string to 'bool' for the isVolatile parameter.
 
LoadInstCreateLoad (Type *Ty, Value *Ptr, const Twine &Name="")
 
LoadInstCreateLoad (Type *Ty, Value *Ptr, bool isVolatile, const Twine &Name="")
 
StoreInstCreateStore (Value *Val, Value *Ptr, bool isVolatile=false)
 
LoadInstCreateAlignedLoad (Type *Ty, Value *Ptr, MaybeAlign Align, const char *Name)
 
LoadInstCreateAlignedLoad (Type *Ty, Value *Ptr, MaybeAlign Align, const Twine &Name="")
 
LoadInstCreateAlignedLoad (Type *Ty, Value *Ptr, MaybeAlign Align, bool isVolatile, const Twine &Name="")
 
StoreInstCreateAlignedStore (Value *Val, Value *Ptr, MaybeAlign Align, bool isVolatile=false)
 
FenceInstCreateFence (AtomicOrdering Ordering, SyncScope::ID SSID=SyncScope::System, const Twine &Name="")
 
AtomicCmpXchgInstCreateAtomicCmpXchg (Value *Ptr, Value *Cmp, Value *New, MaybeAlign Align, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SyncScope::ID SSID=SyncScope::System)
 
AtomicRMWInstCreateAtomicRMW (AtomicRMWInst::BinOp Op, Value *Ptr, Value *Val, MaybeAlign Align, AtomicOrdering Ordering, SyncScope::ID SSID=SyncScope::System)
 
ValueCreateGEP (Type *Ty, Value *Ptr, ArrayRef< Value * > IdxList, const Twine &Name="", bool IsInBounds=false)
 
ValueCreateInBoundsGEP (Type *Ty, Value *Ptr, ArrayRef< Value * > IdxList, const Twine &Name="")
 
ValueCreateConstGEP1_32 (Type *Ty, Value *Ptr, unsigned Idx0, const Twine &Name="")
 
ValueCreateConstInBoundsGEP1_32 (Type *Ty, Value *Ptr, unsigned Idx0, const Twine &Name="")
 
ValueCreateConstGEP2_32 (Type *Ty, Value *Ptr, unsigned Idx0, unsigned Idx1, const Twine &Name="")
 
ValueCreateConstInBoundsGEP2_32 (Type *Ty, Value *Ptr, unsigned Idx0, unsigned Idx1, const Twine &Name="")
 
ValueCreateConstGEP1_64 (Type *Ty, Value *Ptr, uint64_t Idx0, const Twine &Name="")
 
ValueCreateConstInBoundsGEP1_64 (Type *Ty, Value *Ptr, uint64_t Idx0, const Twine &Name="")
 
ValueCreateConstGEP2_64 (Type *Ty, Value *Ptr, uint64_t Idx0, uint64_t Idx1, const Twine &Name="")
 
ValueCreateConstInBoundsGEP2_64 (Type *Ty, Value *Ptr, uint64_t Idx0, uint64_t Idx1, const Twine &Name="")
 
ValueCreateStructGEP (Type *Ty, Value *Ptr, unsigned Idx, const Twine &Name="")
 
ValueCreatePtrAdd (Value *Ptr, Value *Offset, const Twine &Name="", bool IsInBounds=false)
 
ValueCreateInBoundsPtrAdd (Value *Ptr, Value *Offset, const Twine &Name="")
 
ConstantCreateGlobalStringPtr (StringRef Str, const Twine &Name="", unsigned AddressSpace=0, Module *M=nullptr)
 Same as CreateGlobalString, but return a pointer with "i8*" type instead of a pointer to array of i8.
 
ValueCreateTrunc (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateZExt (Value *V, Type *DestTy, const Twine &Name="", bool IsNonNeg=false)
 
ValueCreateSExt (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateZExtOrTrunc (Value *V, Type *DestTy, const Twine &Name="")
 Create a ZExt or Trunc from the integer value V to DestTy.
 
ValueCreateSExtOrTrunc (Value *V, Type *DestTy, const Twine &Name="")
 Create a SExt or Trunc from the integer value V to DestTy.
 
ValueCreateFPToUI (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateFPToSI (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateUIToFP (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateSIToFP (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateFPTrunc (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateFPExt (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreatePtrToInt (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateIntToPtr (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateBitCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateAddrSpaceCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateZExtOrBitCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateSExtOrBitCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateTruncOrBitCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateCast (Instruction::CastOps Op, Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreatePointerCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreatePointerBitCastOrAddrSpaceCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateIntCast (Value *V, Type *DestTy, bool isSigned, const Twine &Name="")
 
ValueCreateBitOrPointerCast (Value *V, Type *DestTy, const Twine &Name="")
 
ValueCreateFPCast (Value *V, Type *DestTy, const Twine &Name="")
 
CallInstCreateConstrainedFPCast (Intrinsic::ID ID, Value *V, Type *DestTy, Instruction *FMFSource=nullptr, const Twine &Name="", MDNode *FPMathTag=nullptr, std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt)
 
ValueCreateIntCast (Value *, Type *, const char *)=delete
 
ValueCreateICmpEQ (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpNE (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpUGT (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpUGE (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpULT (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpULE (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpSGT (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpSGE (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpSLT (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateICmpSLE (Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateFCmpOEQ (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpOGT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpOGE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpOLT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpOLE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpONE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpORD (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpUNO (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpUEQ (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpUGT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpUGE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpULT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpULE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpUNE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateICmp (CmpInst::Predicate P, Value *LHS, Value *RHS, const Twine &Name="")
 
ValueCreateFCmp (CmpInst::Predicate P, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateCmp (CmpInst::Predicate Pred, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
ValueCreateFCmpS (CmpInst::Predicate P, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
CallInstCreateConstrainedFPCmp (Intrinsic::ID ID, CmpInst::Predicate P, Value *L, Value *R, const Twine &Name="", std::optional< fp::ExceptionBehavior > Except=std::nullopt)
 
PHINodeCreatePHI (Type *Ty, unsigned NumReservedValues, const Twine &Name="")
 
CallInstCreateCall (FunctionType *FTy, Value *Callee, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
CallInstCreateCall (FunctionType *FTy, Value *Callee, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
CallInstCreateCall (FunctionCallee Callee, ArrayRef< Value * > Args=std::nullopt, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
CallInstCreateCall (FunctionCallee Callee, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="", MDNode *FPMathTag=nullptr)
 
CallInstCreateConstrainedFPCall (Function *Callee, ArrayRef< Value * > Args, const Twine &Name="", std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt)
 
ValueCreateSelect (Value *C, Value *True, Value *False, const Twine &Name="", Instruction *MDFrom=nullptr)
 
VAArgInstCreateVAArg (Value *List, Type *Ty, const Twine &Name="")
 
ValueCreateExtractElement (Value *Vec, Value *Idx, const Twine &Name="")
 
ValueCreateExtractElement (Value *Vec, uint64_t Idx, const Twine &Name="")
 
ValueCreateInsertElement (Type *VecTy, Value *NewElt, Value *Idx, const Twine &Name="")
 
ValueCreateInsertElement (Type *VecTy, Value *NewElt, uint64_t Idx, const Twine &Name="")
 
ValueCreateInsertElement (Value *Vec, Value *NewElt, Value *Idx, const Twine &Name="")
 
ValueCreateInsertElement (Value *Vec, Value *NewElt, uint64_t Idx, const Twine &Name="")
 
ValueCreateShuffleVector (Value *V1, Value *V2, Value *Mask, const Twine &Name="")
 
ValueCreateShuffleVector (Value *V1, Value *V2, ArrayRef< int > Mask, const Twine &Name="")
 See class ShuffleVectorInst for a description of the mask representation.
 
ValueCreateShuffleVector (Value *V, ArrayRef< int > Mask, const Twine &Name="")
 Create a unary shuffle.
 
ValueCreateExtractValue (Value *Agg, ArrayRef< unsigned > Idxs, const Twine &Name="")
 
ValueCreateInsertValue (Value *Agg, Value *Val, ArrayRef< unsigned > Idxs, const Twine &Name="")
 
LandingPadInstCreateLandingPad (Type *Ty, unsigned NumClauses, const Twine &Name="")
 
ValueCreateFreeze (Value *V, const Twine &Name="")
 
ValueCreateIsNull (Value *Arg, const Twine &Name="")
 Return a boolean value testing if Arg == 0.
 
ValueCreateIsNotNull (Value *Arg, const Twine &Name="")
 Return a boolean value testing if Arg != 0.
 
ValueCreateIsNeg (Value *Arg, const Twine &Name="")
 Return a boolean value testing if Arg < 0.
 
ValueCreateIsNotNeg (Value *Arg, const Twine &Name="")
 Return a boolean value testing if Arg > -1.
 
ValueCreatePtrDiff (Type *ElemTy, Value *LHS, Value *RHS, const Twine &Name="")
 Return the i64 difference between two pointer values, dividing out the size of the pointed-to objects.
 
ValueCreateLaunderInvariantGroup (Value *Ptr)
 Create a launder.invariant.group intrinsic call.
 
ValueCreateStripInvariantGroup (Value *Ptr)
 Create a strip.invariant.group intrinsic call.
 
ValueCreateVectorReverse (Value *V, const Twine &Name="")
 Return a vector value that contains the vector V reversed.
 
ValueCreateVectorSplice (Value *V1, Value *V2, int64_t Imm, const Twine &Name="")
 Return a vector splice intrinsic if using scalable vectors, otherwise return a shufflevector.
 
ValueCreateVectorSplat (unsigned NumElts, Value *V, const Twine &Name="")
 Return a vector value that contains.
 
ValueCreateVectorSplat (ElementCount EC, Value *V, const Twine &Name="")
 Return a vector value that contains.
 
ValueCreatePreserveArrayAccessIndex (Type *ElTy, Value *Base, unsigned Dimension, unsigned LastIndex, MDNode *DbgInfo)
 
ValueCreatePreserveUnionAccessIndex (Value *Base, unsigned FieldIndex, MDNode *DbgInfo)
 
ValueCreatePreserveStructAccessIndex (Type *ElTy, Value *Base, unsigned Index, unsigned FieldIndex, MDNode *DbgInfo)
 
ValuecreateIsFPClass (Value *FPNum, unsigned Test)
 
CallInstCreateAlignmentAssumption (const DataLayout &DL, Value *PtrValue, unsigned Alignment, Value *OffsetValue=nullptr)
 Create an assume intrinsic call that represents an alignment assumption on the provided pointer.
 
CallInstCreateAlignmentAssumption (const DataLayout &DL, Value *PtrValue, Value *Alignment, Value *OffsetValue=nullptr)
 Create an assume intrinsic call that represents an alignment assumption on the provided pointer.
 

Protected Attributes

BasicBlockBB
 
BasicBlock::iterator InsertPt
 
LLVMContextContext
 
const IRBuilderFolderFolder
 
const IRBuilderDefaultInserterInserter
 
MDNodeDefaultFPMathTag
 
FastMathFlags FMF
 
bool IsFPConstrained = false
 
fp::ExceptionBehavior DefaultConstrainedExcept = fp::ebStrict
 
RoundingMode DefaultConstrainedRounding = RoundingMode::Dynamic
 
ArrayRef< OperandBundleDefDefaultOperandBundles
 

Detailed Description

Common base class shared among various IRBuilders.

Definition at line 94 of file IRBuilder.h.

Constructor & Destructor Documentation

◆ IRBuilderBase()

llvm::IRBuilderBase::IRBuilderBase ( LLVMContext context,
const IRBuilderFolder Folder,
const IRBuilderDefaultInserter Inserter,
MDNode FPMathTag,
ArrayRef< OperandBundleDef OpBundles 
)
inline

Definition at line 135 of file IRBuilder.h.

References ClearInsertionPoint().

Member Function Documentation

◆ AddMetadataToInst()

void llvm::IRBuilderBase::AddMetadataToInst ( Instruction I) const
inline

Add all entries in MetadataToCopy to I.

Definition at line 241 of file IRBuilder.h.

References I.

Referenced by Insert().

◆ clearFastMathFlags()

void llvm::IRBuilderBase::clearFastMathFlags ( )
inline

Clear the fast-math flags.

Definition at line 299 of file IRBuilder.h.

References llvm::FastMathFlags::clear(), and FMF.

◆ ClearInsertionPoint()

void llvm::IRBuilderBase::ClearInsertionPoint ( )
inline

Clear the insertion point: created instructions will not be inserted into a block.

Definition at line 169 of file IRBuilder.h.

References BB, and InsertPt.

Referenced by llvm::SCEVExpander::clearInsertPoint(), llvm::OpenMPIRBuilder::emitBranch(), IRBuilderBase(), llvm::Negator::Negate(), restoreIP(), and saveAndClearIP().

◆ CollectMetadataToCopy()

void llvm::IRBuilderBase::CollectMetadataToCopy ( Instruction Src,
ArrayRef< unsigned MetadataKinds 
)
inline

Collect metadata with IDs MetadataKinds from Src which should be added to all created instructions.

Entries present in MedataDataToCopy but not on Src will be dropped from MetadataToCopy.

Definition at line 227 of file IRBuilder.h.

Referenced by performBranchToCommonDestFolding(), and llvm::InstCombinerImpl::run().

◆ CreateAdd()

Value * llvm::IRBuilderBase::CreateAdd ( Value LHS,
Value RHS,
const Twine Name = "",
bool  HasNUW = false,
bool  HasNSW = false 
)
inline

Definition at line 1321 of file IRBuilder.h.

References Folder, llvm::IRBuilderFolder::FoldNoWrapBinOp(), LHS, Name, and RHS.

Referenced by llvm::buildAtomicRMWValue(), callBufferedPrintfStart(), CheckAndCreateOffsetAdd(), CloneLoopBlocks(), llvm::InstCombinerImpl::commonIDivTransforms(), llvm::OpenMPIRBuilder::createCanonicalLoop(), createFakeIntVal(), llvm::OpenMPIRBuilder::createLoopSkeleton(), llvm::createMemCpyLoopKnownSize(), createMemMoveLoop(), createMemSetLoop(), CreateNSWAdd(), CreateNUWAdd(), llvm::emitGEPOffset(), llvm::VPWidenPointerInductionRecipe::execute(), llvm::VPWidenCanonicalIVRecipe::execute(), llvm::VPScalarIVStepsRecipe::execute(), expandFPToI(), expandIToFP(), llvm::InstCombinerImpl::foldCmpLoadFromIndexedGlobal(), llvm::InstCombinerImpl::foldFMulReassoc(), llvm::InstCombinerImpl::foldICmpAddConstant(), llvm::InstCombinerImpl::foldICmpBinOp(), llvm::InstCombinerImpl::foldICmpEquality(), llvm::InstCombinerImpl::foldICmpSubConstant(), foldICmpUSubSatOrUAddSatWithConstant(), foldICmpWithTruncSignExtendedVal(), llvm::InstCombinerImpl::foldICmpXorShiftConst(), llvm::InstCombinerImpl::foldIRemByPowerOfTwoToBitTest(), foldMulShl1(), foldNoWrapAdd(), llvm::InstCombinerImpl::foldSquareSumInt(), llvm::SCEVExpander::generateOverflowCheck(), generateUnsignedDivisionCode(), llvm::InstCombiner::getFreelyInvertedImpl(), llvm::InnerLoopVectorizer::getOrCreateVectorTripCount(), getStepVector(), getStrlenWithNull(), hoistSub(), insertSpills(), LowerCTPOP(), matchStridedStart(), promoteAllocaUserToVector(), simplifyAMDGCNMemoryIntrinsicDemanded(), llvm::SplitBlockAndInsertSimpleForLoop(), takeLog2(), llvm::OpenMPIRBuilder::tileLoops(), llvm::InstCombinerImpl::tryFoldInstWithCtpopWithNot(), llvm::UnrollRuntimeLoopRemainder(), llvm::UpgradeIntrinsicCall(), llvm::InnerLoopVectorizer::vectorizeInterleaveGroup(), llvm::InstCombinerImpl::visitAdd(), llvm::InstCombinerImpl::visitCallInst(), llvm::InstCombinerImpl::visitFDiv(), llvm::ObjectSizeOffsetEvaluator::visitGEPOperator(), llvm::InstCombinerImpl::visitLShr(), llvm::InstCombinerImpl::visitOr(), llvm::InstCombinerImpl::visitSub(), and llvm::InstCombinerImpl::visitURem().

◆ CreateAddReduce()

CallInst * IRBuilderBase::CreateAddReduce ( Value Src)

Create a vector int add reduction intrinsic of the source vector.

Definition at line 433 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction(), and llvm::InstCombinerImpl::visitCallInst().

◆ CreateAddrSpaceCast()

Value * llvm::IRBuilderBase::CreateAddrSpaceCast ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateAggregateRet()

ReturnInst * llvm::IRBuilderBase::CreateAggregateRet ( Value *const retVals,
unsigned  N 
)
inline

Create a sequence of N insertvalue instructions, with one Value from the retVals array each, that build a aggregate return value one value at a time, and a ret instruction to return the resulting aggregate value.

This is a convenience function for code that uses aggregate return values as a vehicle for having multiple return values.

Definition at line 1100 of file IRBuilder.h.

References Context, llvm::ReturnInst::Create(), CreateInsertValue(), llvm::PoisonValue::get(), getCurrentFunctionReturnType(), Insert(), and N.

◆ CreateAlignedLoad() [1/3]

LoadInst * llvm::IRBuilderBase::CreateAlignedLoad ( Type Ty,
Value Ptr,
MaybeAlign  Align,
bool  isVolatile,
const Twine Name = "" 
)
inline

◆ CreateAlignedLoad() [2/3]

LoadInst * llvm::IRBuilderBase::CreateAlignedLoad ( Type Ty,
Value Ptr,
MaybeAlign  Align,
const char Name 
)
inline

◆ CreateAlignedLoad() [3/3]

LoadInst * llvm::IRBuilderBase::CreateAlignedLoad ( Type Ty,
Value Ptr,
MaybeAlign  Align,
const Twine Name = "" 
)
inline

Definition at line 1811 of file IRBuilder.h.

References CreateAlignedLoad(), Name, and Ptr.

◆ CreateAlignedStore()

StoreInst * llvm::IRBuilderBase::CreateAlignedStore ( Value Val,
Value Ptr,
MaybeAlign  Align,
bool  isVolatile = false 
)
inline

◆ CreateAlignmentAssumption() [1/2]

CallInst * IRBuilderBase::CreateAlignmentAssumption ( const DataLayout DL,
Value PtrValue,
unsigned  Alignment,
Value OffsetValue = nullptr 
)

Create an assume intrinsic call that represents an alignment assumption on the provided pointer.

An optional offset can be provided, and if it is provided, the offset must be subtracted from the provided pointer to get the pointer with the specified alignment.

Definition at line 1326 of file IRBuilder.cpp.

References assert(), DL, getIntPtrTy(), and llvm::Value::getType().

Referenced by AddAlignmentAssumptions(), and llvm::OpenMPIRBuilder::applySimd().

◆ CreateAlignmentAssumption() [2/2]

CallInst * IRBuilderBase::CreateAlignmentAssumption ( const DataLayout DL,
Value PtrValue,
Value Alignment,
Value OffsetValue = nullptr 
)

Create an assume intrinsic call that represents an alignment assumption on the provided pointer.

An optional offset can be provided, and if it is provided, the offset must be subtracted from the provided pointer to get the pointer with the specified alignment.

This overload handles the condition where the Alignment is dependent on an existing value rather than a static value.

Definition at line 1339 of file IRBuilder.cpp.

References assert(), DL, and llvm::Value::getType().

◆ CreateAlloca() [1/2]

AllocaInst * llvm::IRBuilderBase::CreateAlloca ( Type Ty,
unsigned  AddrSpace,
Value ArraySize = nullptr,
const Twine Name = "" 
)
inline

◆ CreateAlloca() [2/2]

AllocaInst * llvm::IRBuilderBase::CreateAlloca ( Type Ty,
Value ArraySize = nullptr,
const Twine Name = "" 
)
inline

◆ CreateAnd() [1/4]

Value * llvm::IRBuilderBase::CreateAnd ( ArrayRef< Value * >  Ops)
inline

◆ CreateAnd() [2/4]

Value * llvm::IRBuilderBase::CreateAnd ( Value LHS,
const APInt RHS,
const Twine Name = "" 
)
inline

Definition at line 1475 of file IRBuilder.h.

References CreateAnd(), LHS, Name, and RHS.

◆ CreateAnd() [3/4]

Value * llvm::IRBuilderBase::CreateAnd ( Value LHS,
uint64_t  RHS,
const Twine Name = "" 
)
inline

Definition at line 1479 of file IRBuilder.h.

References CreateAnd(), LHS, Name, and RHS.

◆ CreateAnd() [4/4]

Value * llvm::IRBuilderBase::CreateAnd ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1469 of file IRBuilder.h.

References llvm::IRBuilderFolder::FoldBinOp(), Folder, Insert(), LHS, Name, and RHS.

Referenced by llvm::addRuntimeChecks(), applyX86MaskOn1BitsVec(), llvm::buildAtomicRMWValue(), buildPartialUnswitchConditionalBranch(), callBufferedPrintfStart(), checkForNegativeOperand(), llvm::InstCombinerImpl::commonShiftTransforms(), CreateAnd(), createLogicFromTable(), createMaskInstrs(), expandFPToI(), expandIToFP(), foldAnyOrAllBitsSet(), llvm::InstCombinerImpl::foldCmpLoadFromIndexedGlobal(), foldComplexAndOrPatterns(), foldCtpopPow2Test(), llvm::InstCombinerImpl::foldICmpAddConstant(), llvm::InstCombinerImpl::foldICmpAndConstant(), llvm::InstCombinerImpl::foldICmpAndConstConst(), llvm::InstCombinerImpl::foldICmpAndShift(), llvm::InstCombinerImpl::foldICmpBinOp(), llvm::InstCombinerImpl::foldICmpBinOpEqualityWithConstant(), llvm::InstCombinerImpl::foldICmpEqIntrinsicWithConstant(), llvm::InstCombinerImpl::foldICmpEquality(), llvm::InstCombinerImpl::foldICmpIntrinsicWithConstant(), llvm::InstCombinerImpl::foldICmpOrConstant(), foldICmpOrXX(), llvm::InstCombinerImpl::foldICmpShlConstant(), llvm::InstCombinerImpl::foldICmpShrConstant(), llvm::InstCombinerImpl::foldICmpSRemConstant(), llvm::InstCombinerImpl::foldICmpTruncConstant(), llvm::InstCombinerImpl::foldICmpWithTrunc(), foldICmpXNegX(), llvm::InstCombinerImpl::foldIRemByPowerOfTwoToBitTest(), foldLogOpOfMaskedICmps(), foldLogOpOfMaskedICmps_NotAllZeros_BMask_Mixed(), foldOrToXor(), foldSelectICmpAnd(), foldSelectICmpAndAnd(), foldSelectICmpAndBinOp(), foldShiftedShift(), foldShiftIntoShiftInAnotherHandOfAndInICmp(), foldSwitchToSelect(), llvm::SCEVExpander::generateOverflowCheck(), generateUnsignedDivisionCode(), insertMaskedValue(), insertSpills(), llvm::X86TTIImpl::instCombineIntrinsic(), LowerBSWAP(), LowerCTPOP(), llvm::IntrinsicLowering::LowerIntrinsicCall(), performMaskedAtomicOp(), processUMulZExtIdiom(), llvm::KCFIPass::run(), scalarizeMaskedCompressStore(), scalarizeMaskedExpandLoad(), scalarizeMaskedGather(), scalarizeMaskedLoad(), scalarizeMaskedScatter(), scalarizeMaskedStore(), llvm::InstCombinerImpl::SimplifyDemandedUseBits(), simplifyTernarylogic(), llvm::UpgradeIntrinsicCall(), upgradeMaskedMove(), upgradePMULDQ(), llvm::InstCombinerImpl::visitAnd(), llvm::InstCombinerImpl::visitAShr(), llvm::InstCombinerImpl::visitBitCast(), llvm::InstCombinerImpl::visitCallInst(), llvm::InstCombinerImpl::visitFCmpInst(), llvm::InstCombinerImpl::visitICmpInst(), llvm::InstCombinerImpl::visitLShr(), visitMaskedMerge(), llvm::InstCombinerImpl::visitMul(), llvm::InstCombinerImpl::visitOr(), llvm::InstCombinerImpl::visitShl(), llvm::InstCombinerImpl::visitSub(), llvm::InstCombinerImpl::visitSwitchInst(), llvm::InstCombinerImpl::visitTrunc(), llvm::InstCombinerImpl::visitXor(), and llvm::InstCombinerImpl::visitZExt().

◆ CreateAndReduce()

CallInst * IRBuilderBase::CreateAndReduce ( Value Src)

Create a vector int AND reduction intrinsic of the source vector.

Definition at line 441 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction(), and llvm::InstCombinerImpl::visitCallInst().

◆ CreateArithmeticFence()

CallInst * llvm::IRBuilderBase::CreateArithmeticFence ( Value Val,
Type DstType,
const Twine Name = "" 
)
inline

Create a call to the arithmetic_fence intrinsic.

Definition at line 1024 of file IRBuilder.h.

References CreateIntrinsic(), and Name.

◆ CreateAShr() [1/3]

Value * llvm::IRBuilderBase::CreateAShr ( Value LHS,
const APInt RHS,
const Twine Name = "",
bool  isExact = false 
)
inline

Definition at line 1459 of file IRBuilder.h.

References CreateAShr(), LHS, Name, and RHS.

◆ CreateAShr() [2/3]

Value * llvm::IRBuilderBase::CreateAShr ( Value LHS,
uint64_t  RHS,
const Twine Name = "",
bool  isExact = false 
)
inline

Definition at line 1464 of file IRBuilder.h.

References CreateAShr(), LHS, Name, and RHS.

◆ CreateAShr() [3/3]

Value * llvm::IRBuilderBase::CreateAShr ( Value LHS,
Value RHS,
const Twine Name = "",
bool  isExact = false 
)
inline

◆ CreateAssumption()

CallInst * IRBuilderBase::CreateAssumption ( Value Cond,
ArrayRef< OperandBundleDef OpBundles = std::nullopt 
)

Create an assume intrinsic call that allows the optimizer to assume that the provided condition will be true.

The optional argument OpBundles specifies operand bundles that are added to the call instruction.

Definition at line 551 of file IRBuilder.cpp.

References assert(), BB, Cond, CreateCall(), llvm::Intrinsic::getDeclaration(), getInt1Ty(), llvm::GlobalValue::getParent(), and llvm::BasicBlock::getParent().

Referenced by generateReproducer(), llvm::lowerObjectSizeCall(), and removeUndefIntroducingPredecessor().

◆ CreateAtomicCmpXchg()

AtomicCmpXchgInst * llvm::IRBuilderBase::CreateAtomicCmpXchg ( Value Ptr,
Value Cmp,
Value New,
MaybeAlign  Align,
AtomicOrdering  SuccessOrdering,
AtomicOrdering  FailureOrdering,
SyncScope::ID  SSID = SyncScope::System 
)
inline

◆ CreateAtomicRMW()

AtomicRMWInst * llvm::IRBuilderBase::CreateAtomicRMW ( AtomicRMWInst::BinOp  Op,
Value Ptr,
Value Val,
MaybeAlign  Align,
AtomicOrdering  Ordering,
SyncScope::ID  SSID = SyncScope::System 
)
inline

◆ CreateBinaryIntrinsic()

CallInst * IRBuilderBase::CreateBinaryIntrinsic ( Intrinsic::ID  ID,
Value LHS,
Value RHS,
Instruction FMFSource = nullptr,
const Twine Name = "" 
)

◆ CreateBinOp()

Value * llvm::IRBuilderBase::CreateBinOp ( Instruction::BinaryOps  Opc,
Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 1660 of file IRBuilder.h.

References llvm::BinaryOperator::Create(), FMF, llvm::IRBuilderFolder::FoldBinOp(), Folder, Insert(), LHS, Name, and RHS.

Referenced by buildNew(), canonicalizeLogicFirst(), llvm::InstCombinerImpl::commonShiftTransforms(), createLogicalOp(), CreateNAryOp(), llvm::VPWidenIntOrFpInductionRecipe::execute(), llvm::VPReductionRecipe::execute(), llvm::VPScalarIVStepsRecipe::execute(), factorizeMathWithShlOps(), foldAndOrOfICmpsWithConstEq(), llvm::InstCombinerImpl::foldBinOpOfSelectAndCastOfSelectCondition(), llvm::InstCombinerImpl::foldBinOpShiftWithShift(), llvm::InstCombinerImpl::foldBinopWithPhiOperands(), foldBitCastBitwiseLogic(), foldBitwiseLogicWithIntrinsics(), foldComplexAndOrPatterns(), foldDependentIVs(), foldICmpOrXorSubChain(), foldLogicCastConstant(), foldSelectICmpAndBinOp(), llvm::InstCombinerImpl::foldSelectShuffle(), llvm::InstCombinerImpl::FoldShiftByConstant(), foldShiftOfShiftedBinOp(), llvm::InstCombinerImpl::foldUsingDistributiveLaws(), llvm::InstCombinerImpl::foldVectorBinop(), llvm::getOrderedReduction(), llvm::getShuffleReduction(), getStepVector(), instCombineSVEVectorBinOp(), matchDeMorgansLaws(), narrowUDivURem(), reassociateForUses(), simplifyAndOrWithOpReplaced(), llvm::InstCombinerImpl::simplifyBinOpSplats(), llvm::X86TTIImpl::simplifyDemandedVectorEltsIntrinsic(), llvm::InstCombinerImpl::SimplifySelectsFeedingBinaryOp(), llvm::InstCombinerImpl::sinkNotIntoLogicalOp(), llvm::InstCombinerImpl::sinkNotIntoOtherHandOfLogicalOp(), tryFactorization(), llvm::InnerLoopVectorizer::vectorizeInterleaveGroup(), llvm::InstCombinerImpl::visitAnd(), llvm::InstCombinerImpl::visitMul(), and llvm::InstCombinerImpl::visitShl().

◆ CreateBitCast()

Value * llvm::IRBuilderBase::CreateBitCast ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

Definition at line 2110 of file IRBuilder.h.

References CreateCast(), and Name.

Referenced by applyX86MaskOn1BitsVec(), canonicalizeBitCastExtElt(), llvm::VNCoercion::coerceAvailableValueToLoadType(), llvm::OpenMPIRBuilder::createAtomicCompare(), llvm::OpenMPIRBuilder::createAtomicRead(), llvm::OpenMPIRBuilder::createAtomicWrite(), CreateBitOrPointerCast(), createCast(), createCmpXchgInstFun(), llvm::OpenMPIRBuilder::createReductions(), createTargetLoopWorkshareCall(), createTblForTrunc(), createTblShuffleForZExt(), llvm::coro::Shape::emitDealloc(), llvm::AArch64TargetLowering::emitLoadLinked(), llvm::HexagonTargetLowering::emitLoadLinked(), llvm::AArch64TargetLowering::emitStoreConditional(), llvm::HexagonTargetLowering::emitStoreConditional(), emitX86ScalarSelect(), expandFPToI(), expandIToFP(), extractMaskedValue(), fitArgInto64Bits(), foldBitCastBitwiseLogic(), foldBitCastSelect(), llvm::InstCombinerImpl::foldICmpBitCast(), foldReductionIdiom(), foldTruncInsEltPair(), foldVecTruncToExtElt(), getAllocaPos(), llvm::VNCoercion::getStoreValueForLoadHelper(), getX86MaskVec(), hostParallelCallback(), llvm::InlineFunction(), insertMaskedValue(), llvm::objcarc::BundledRetainClaimRVs::insertRVCallWithColors(), llvm::PPCTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), instCombineLD1GatherIndex(), instCombineST1ScatterIndex(), instCombineSVECondLast(), lowerKernelArguments(), optimizeVectorResizeWithIntegerBitCasts(), promoteAllocaUserToVector(), scalarizeMaskedCompressStore(), scalarizeMaskedExpandLoad(), scalarizeMaskedGather(), scalarizeMaskedLoad(), scalarizeMaskedScatter(), scalarizeMaskedStore(), simplifyNeonVld1(), simplifyRelocatesOffABase(), simplifyX86extrq(), simplifyX86insertq(), simplifyX86MaskedLoad(), simplifyX86MaskedStore(), simplifyX86movmsk(), splitMergedValStore(), splitRetconCoroutine(), targetParallelCallback(), llvm::UpgradeARCRuntime(), llvm::UpgradeIntrinsicCall(), upgradeMaskedLoad(), upgradeMaskedStore(), upgradePMULDQ(), upgradeX86PSLLDQIntrinsics(), upgradeX86PSRLDQIntrinsics(), upgradeX86VPERMT2Intrinsics(), llvm::versionCallSite(), llvm::InstCombinerImpl::visitBitCast(), llvm::InstCombinerImpl::visitCallInst(), llvm::InstCombinerImpl::visitFCmpInst(), llvm::InstCombinerImpl::visitShuffleVectorInst(), and llvm::InstCombinerImpl::visitTrunc().

◆ CreateBitOrPointerCast()

Value * llvm::IRBuilderBase::CreateBitOrPointerCast ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateBr()

BranchInst * llvm::IRBuilderBase::CreateBr ( BasicBlock Dest)
inline

◆ CreateCall() [1/4]

CallInst * llvm::IRBuilderBase::CreateCall ( FunctionCallee  Callee,
ArrayRef< Value * >  Args,
ArrayRef< OperandBundleDef OpBundles,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2424 of file IRBuilder.h.

References CreateCall(), and Name.

◆ CreateCall() [2/4]

CallInst * llvm::IRBuilderBase::CreateCall ( FunctionCallee  Callee,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2417 of file IRBuilder.h.

References CreateCall(), and Name.

◆ CreateCall() [3/4]

CallInst * llvm::IRBuilderBase::CreateCall ( FunctionType FTy,
Value Callee,
ArrayRef< Value * >  Args,
ArrayRef< OperandBundleDef OpBundles,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

◆ CreateCall() [4/4]

CallInst * llvm::IRBuilderBase::CreateCall ( FunctionType FTy,
Value Callee,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2395 of file IRBuilder.h.

References llvm::CallInst::Create(), DefaultOperandBundles, FMF, Insert(), IsFPConstrained, Name, and setConstrainedFPCallAttr().

Referenced by callAppendArgs(), callAppendStringN(), callBufferedPrintfStart(), callIntrinsic(), callPrintfBegin(), convertToRelLookupTable(), CreateAssumption(), llvm::OpenMPIRBuilder::createCachedThreadPrivate(), CreateCall(), llvm::OpenMPIRBuilder::createCancel(), CreateConstrainedFPCall(), llvm::OpenMPIRBuilder::createCopyPrivate(), llvm::OpenMPIRBuilder::createCritical(), llvm::dxil::DXILOpBuilder::createDXILOpCall(), CreateElementUnorderedAtomicMemCpy(), CreateElementUnorderedAtomicMemMove(), CreateElementUnorderedAtomicMemSet(), CreateFAddReduce(), createFFSIntrinsic(), CreateFMulReduce(), CreateFree(), CreateGCGetPointerBase(), CreateGCGetPointerOffset(), CreateGCRelocate(), CreateGCRelocates(), CreateGCResult(), CreateGCStatepointCallCommon(), CreateInvariantStart(), createIsFPClass(), CreateLaunderInvariantGroup(), CreateLifetimeEnd(), CreateLifetimeStart(), CreateMalloc(), llvm::OpenMPIRBuilder::createMasked(), llvm::OpenMPIRBuilder::createMaster(), CreateMemSet(), CreateMemSetInline(), CreateMemTransferInst(), llvm::coro::createMustTailCall(), CreateNoAliasScopeDeclaration(), llvm::OpenMPIRBuilder::createOMPAlloc(), llvm::OpenMPIRBuilder::createOMPFree(), llvm::OpenMPIRBuilder::createOMPInteropDestroy(), llvm::OpenMPIRBuilder::createOMPInteropInit(), llvm::OpenMPIRBuilder::createOMPInteropUse(), llvm::OpenMPIRBuilder::createOrderedDepend(), llvm::OpenMPIRBuilder::createOrderedThreadsSimd(), llvm::OpenMPIRBuilder::createParallel(), createPopcntIntrinsic(), CreatePreserveArrayAccessIndex(), CreatePreserveStructAccessIndex(), CreatePreserveUnionAccessIndex(), llvm::OpenMPIRBuilder::createReductions(), llvm::createSanitizerCtorAndInitFunctions(), llvm::OpenMPIRBuilder::createSingle(), CreateStripInvariantGroup(), llvm::OpenMPIRBuilder::createTargetData(), llvm::OpenMPIRBuilder::createTargetDeinit(), llvm::OpenMPIRBuilder::createTargetInit(), createTargetLoopWorkshareCall(), llvm::OpenMPIRBuilder::createTask(), llvm::OpenMPIRBuilder::createTaskgroup(), createTblForTrunc(), llvm::OpenMPIRBuilder::createTeams(), llvm::VectorBuilder::createVectorInstruction(), CreateVScale(), llvm::orc::IRSpeculationLayer::emit(), llvm::coro::Shape::emitAlloc(), llvm::AArch64TargetLowering::emitAtomicCmpXchgNoStoreLLBalance(), llvm::ARMTargetLowering::emitAtomicCmpXchgNoStoreLLBalance(), llvm::OpenMPIRBuilder::emitBarrierImpl(), llvm::coro::Shape::emitDealloc(), llvm::OpenMPIRBuilder::emitFlush(), emitGetSwiftErrorValue(), llvm::AArch64TargetLowering::emitLoadLinked(), llvm::ARMTargetLowering::emitLoadLinked(), llvm::HexagonTargetLowering::emitLoadLinked(), llvm::OpenMPIRBuilder::emitMapperCall(), llvm::LoongArchTargetLowering::emitMaskedAtomicCmpXchgIntrinsic(), llvm::PPCTargetLowering::emitMaskedAtomicCmpXchgIntrinsic(), llvm::RISCVTargetLowering::emitMaskedAtomicCmpXchgIntrinsic(), llvm::LoongArchTargetLowering::emitMaskedAtomicRMWIntrinsic(), llvm::PPCTargetLowering::emitMaskedAtomicRMWIntrinsic(), llvm::RISCVTargetLowering::emitMaskedAtomicRMWIntrinsic(), emitSetSwiftErrorValue(), llvm::AArch64TargetLowering::emitStoreConditional(), llvm::ARMTargetLowering::emitStoreConditional(), llvm::HexagonTargetLowering::emitStoreConditional(), emitTargetCall(), llvm::OpenMPIRBuilder::emitTargetKernel(), llvm::OpenMPIRBuilder::emitTaskwaitImpl(), llvm::OpenMPIRBuilder::emitTaskyieldImpl(), emitTPIDR2Save(), llvm::PPCTargetLowering::emitTrailingFence(), llvm::VPWidenCallRecipe::execute(), expandIToFP(), FlattenLoopPair(), foldCtpop(), foldGuardedFunnelShift(), llvm::InstCombinerImpl::foldMultiplicationOverflowCheck(), foldSqrt(), llvm::SCEVExpander::generateOverflowCheck(), generateUnsignedDivisionCode(), llvm::OpenMPIRBuilder::getOrCreateThreadID(), llvm::TargetLoweringBase::getSafeStackPointerLocation(), hostParallelCallback(), llvm::InlineFunction(), inlineRetainOrClaimRVCalls(), llvm::GCNTTIImpl::instCombineIntrinsic(), instrumentOneFunc(), llvm::SampleProfileProber::instrumentOneFunc(), llvm::AArch64TargetLowering::lowerDeinterleaveIntrinsicToLoad(), llvm::RISCVTargetLowering::lowerDeinterleaveIntrinsicToLoad(), llvm::lowerGlobalIFuncUsersAsGlobalCtor(), llvm::AArch64TargetLowering::lowerInterleavedLoad(), llvm::ARMTargetLowering::lowerInterleavedLoad(), llvm::RISCVTargetLowering::lowerInterleavedLoad(), llvm::AArch64TargetLowering::lowerInterleavedStore(), llvm::ARMTargetLowering::lowerInterleavedStore(), llvm::RISCVTargetLowering::lowerInterleavedStore(), llvm::AArch64TargetLowering::lowerInterleaveIntrinsicToStore(), llvm::RISCVTargetLowering::lowerInterleaveIntrinsicToStore(), lowerObjCCall(), llvm::ARMTargetLowering::makeDMB(), llvm::orc::makeStub(), matchOrConcat(), modifyIntrinsicCall(), processUGT_ADDCST_ADD(), processUMulZExtIdiom(), ReplaceCallWith(), replaceWithTLIFunction(), llvm::KCFIPass::run(), simplifyAMDGCNMemoryIntrinsicDemanded(), simplifyX86extrq(), simplifyX86insertq(), targetParallelCallback(), tryToFPToSat(), tryToRecognizePopCount(), upgradeAbs(), llvm::UpgradeARCRuntime(), upgradeARMIntrinsicCall(), upgradeAVX512MaskToSelect(), llvm::UpgradeIntrinsicCall(), upgradeX86BinaryIntrinsics(), upgradeX86ConcatShift(), upgradeX86MaskedShift(), upgradeX86Rotate(), upgradeX86VPERMT2Intrinsics(), UseTlsOffset(), useTpOffset(), and llvm::InstCombinerImpl::visitCallInst().

◆ CreateCallBr() [1/4]

CallBrInst * llvm::IRBuilderBase::CreateCallBr ( FunctionCallee  Callee,
BasicBlock DefaultDest,
ArrayRef< BasicBlock * >  IndirectDests,
ArrayRef< Value * >  Args,
ArrayRef< OperandBundleDef OpBundles,
const Twine Name = "" 
)
inline

Definition at line 1217 of file IRBuilder.h.

References CreateCallBr(), and Name.

◆ CreateCallBr() [2/4]

CallBrInst * llvm::IRBuilderBase::CreateCallBr ( FunctionCallee  Callee,
BasicBlock DefaultDest,
ArrayRef< BasicBlock * >  IndirectDests,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "" 
)
inline

Definition at line 1210 of file IRBuilder.h.

References CreateCallBr(), and Name.

◆ CreateCallBr() [3/4]

CallBrInst * llvm::IRBuilderBase::CreateCallBr ( FunctionType Ty,
Value Callee,
BasicBlock DefaultDest,
ArrayRef< BasicBlock * >  IndirectDests,
ArrayRef< Value * >  Args,
ArrayRef< OperandBundleDef OpBundles,
const Twine Name = "" 
)
inline

Definition at line 1199 of file IRBuilder.h.

References llvm::CallBrInst::Create(), Insert(), and Name.

◆ CreateCallBr() [4/4]

CallBrInst * llvm::IRBuilderBase::CreateCallBr ( FunctionType Ty,
Value Callee,
BasicBlock DefaultDest,
ArrayRef< BasicBlock * >  IndirectDests,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "" 
)
inline

Create a callbr instruction.

Definition at line 1191 of file IRBuilder.h.

References llvm::CallBrInst::Create(), Insert(), and Name.

Referenced by CreateCallBr().

◆ CreateCast()

Value * llvm::IRBuilderBase::CreateCast ( Instruction::CastOps  Op,
Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateCatchPad()

CatchPadInst * llvm::IRBuilderBase::CreateCatchPad ( Value ParentPad,
ArrayRef< Value * >  Args,
const Twine Name = "" 
)
inline

Definition at line 1242 of file IRBuilder.h.

References llvm::CatchPadInst::Create(), Insert(), and Name.

◆ CreateCatchRet()

CatchReturnInst * llvm::IRBuilderBase::CreateCatchRet ( CatchPadInst CatchPad,
BasicBlock BB 
)
inline

Definition at line 1253 of file IRBuilder.h.

References BB, llvm::CatchReturnInst::Create(), and Insert().

◆ CreateCatchSwitch()

CatchSwitchInst * llvm::IRBuilderBase::CreateCatchSwitch ( Value ParentPad,
BasicBlock UnwindBB,
unsigned  NumHandlers,
const Twine Name = "" 
)
inline

Definition at line 1235 of file IRBuilder.h.

References llvm::CatchSwitchInst::Create(), Insert(), and Name.

◆ CreateCleanupPad()

CleanupPadInst * llvm::IRBuilderBase::CreateCleanupPad ( Value ParentPad,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "" 
)
inline

Definition at line 1247 of file IRBuilder.h.

References llvm::CleanupPadInst::Create(), Insert(), and Name.

◆ CreateCleanupRet()

CleanupReturnInst * llvm::IRBuilderBase::CreateCleanupRet ( CleanupPadInst CleanupPad,
BasicBlock UnwindBB = nullptr 
)
inline

Definition at line 1230 of file IRBuilder.h.

References llvm::CleanupReturnInst::Create(), and Insert().

Referenced by replaceUnwindCoroEnd().

◆ CreateCmp()

Value * llvm::IRBuilderBase::CreateCmp ( CmpInst::Predicate  Pred,
Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

◆ CreateCondBr() [1/2]

BranchInst * llvm::IRBuilderBase::CreateCondBr ( Value Cond,
BasicBlock True,
BasicBlock False,
Instruction MDSrc 
)
inline

Create a conditional 'br Cond, TrueDest, FalseDest' instruction.

Copy branch meta data if available.

Definition at line 1123 of file IRBuilder.h.

References Cond, llvm::Instruction::copyMetadata(), llvm::BranchInst::Create(), and Insert().

◆ CreateCondBr() [2/2]

BranchInst * llvm::IRBuilderBase::CreateCondBr ( Value Cond,
BasicBlock True,
BasicBlock False,
MDNode BranchWeights = nullptr,
MDNode Unpredictable = nullptr 
)
inline

◆ CreateConstGEP1_32()

Value * llvm::IRBuilderBase::CreateConstGEP1_32 ( Type Ty,
Value Ptr,
unsigned  Idx0,
const Twine Name = "" 
)
inline

◆ CreateConstGEP1_64()

Value * llvm::IRBuilderBase::CreateConstGEP1_64 ( Type Ty,
Value Ptr,
uint64_t  Idx0,
const Twine Name = "" 
)
inline

◆ CreateConstGEP2_32()

Value * llvm::IRBuilderBase::CreateConstGEP2_32 ( Type Ty,
Value Ptr,
unsigned  Idx0,
unsigned  Idx1,
const Twine Name = "" 
)
inline

◆ CreateConstGEP2_64()

Value * llvm::IRBuilderBase::CreateConstGEP2_64 ( Type Ty,
Value Ptr,
uint64_t  Idx0,
uint64_t  Idx1,
const Twine Name = "" 
)
inline

◆ CreateConstInBoundsGEP1_32()

Value * llvm::IRBuilderBase::CreateConstInBoundsGEP1_32 ( Type Ty,
Value Ptr,
unsigned  Idx0,
const Twine Name = "" 
)
inline

◆ CreateConstInBoundsGEP1_64()

Value * llvm::IRBuilderBase::CreateConstInBoundsGEP1_64 ( Type Ty,
Value Ptr,
uint64_t  Idx0,
const Twine Name = "" 
)
inline

◆ CreateConstInBoundsGEP2_32()

Value * llvm::IRBuilderBase::CreateConstInBoundsGEP2_32 ( Type Ty,
Value Ptr,
unsigned  Idx0,
unsigned  Idx1,
const Twine Name = "" 
)
inline

◆ CreateConstInBoundsGEP2_64()

Value * llvm::IRBuilderBase::CreateConstInBoundsGEP2_64 ( Type Ty,
Value Ptr,
uint64_t  Idx0,
uint64_t  Idx1,
const Twine Name = "" 
)
inline

◆ CreateConstrainedFPBinOp()

CallInst * IRBuilderBase::CreateConstrainedFPBinOp ( Intrinsic::ID  ID,
Value L,
Value R,
Instruction FMFSource = nullptr,
const Twine Name = "",
MDNode FPMathTag = nullptr,
std::optional< RoundingMode Rounding = std::nullopt,
std::optional< fp::ExceptionBehavior Except = std::nullopt 
)

◆ CreateConstrainedFPCall()

CallInst * IRBuilderBase::CreateConstrainedFPCall ( Function Callee,
ArrayRef< Value * >  Args,
const Twine Name = "",
std::optional< RoundingMode Rounding = std::nullopt,
std::optional< fp::ExceptionBehavior Except = std::nullopt 
)

◆ CreateConstrainedFPCast()

CallInst * IRBuilderBase::CreateConstrainedFPCast ( Intrinsic::ID  ID,
Value V,
Type DestTy,
Instruction FMFSource = nullptr,
const Twine Name = "",
MDNode FPMathTag = nullptr,
std::optional< RoundingMode Rounding = std::nullopt,
std::optional< fp::ExceptionBehavior Except = std::nullopt 
)

◆ CreateConstrainedFPCmp()

CallInst * IRBuilderBase::CreateConstrainedFPCmp ( Intrinsic::ID  ID,
CmpInst::Predicate  P,
Value L,
Value R,
const Twine Name = "",
std::optional< fp::ExceptionBehavior Except = std::nullopt 
)

◆ CreateConstrainedFPUnroundedBinOp()

CallInst * IRBuilderBase::CreateConstrainedFPUnroundedBinOp ( Intrinsic::ID  ID,
Value L,
Value R,
Instruction FMFSource = nullptr,
const Twine Name = "",
MDNode FPMathTag = nullptr,
std::optional< fp::ExceptionBehavior Except = std::nullopt 
)

◆ CreateCopySign()

CallInst * llvm::IRBuilderBase::CreateCopySign ( Value LHS,
Value RHS,
Instruction FMFSource = nullptr,
const Twine Name = "" 
)
inline

Create call to the copysign intrinsic.

Definition at line 1016 of file IRBuilder.h.

References CreateBinaryIntrinsic(), LHS, Name, and RHS.

Referenced by llvm::InstCombinerImpl::visitFNeg().

◆ CreateElementCount()

Value * IRBuilderBase::CreateElementCount ( Type DstType,
ElementCount  EC 
)

Create an expression which evaluates to the number of elements in EC at runtime.

Definition at line 99 of file IRBuilder.cpp.

References CreateVScale().

Referenced by llvm::SplitBlockAndInsertForEachLane().

◆ CreateElementUnorderedAtomicMemCpy()

CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemCpy ( Value Dst,
Align  DstAlign,
Value Src,
Align  SrcAlign,
Value Size,
uint32_t  ElementSize,
MDNode TBAATag = nullptr,
MDNode TBAAStructTag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)

Create and insert an element unordered-atomic memcpy between the specified pointers.

DstAlign/SrcAlign are the alignments of the Dst/Src pointers, respectively.

If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.

Definition at line 256 of file IRBuilder.cpp.

References assert(), BB, CreateCall(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::Instruction::setMetadata(), and Size.

◆ CreateElementUnorderedAtomicMemMove()

CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemMove ( Value Dst,
Align  DstAlign,
Value Src,
Align  SrcAlign,
Value Size,
uint32_t  ElementSize,
MDNode TBAATag = nullptr,
MDNode TBAAStructTag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)

Create and insert an element unordered-atomic memmove between the specified pointers.

DstAlign/SrcAlign are the alignments of the Dst/Src pointers, respectively.

If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.

Definition at line 372 of file IRBuilder.cpp.

References llvm::CallBase::addParamAttr(), assert(), BB, CreateCall(), llvm::Value::getContext(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::Attribute::getWithAlignment(), llvm::Instruction::setMetadata(), and Size.

◆ CreateElementUnorderedAtomicMemSet() [1/2]

CallInst * llvm::IRBuilderBase::CreateElementUnorderedAtomicMemSet ( Value Ptr,
Value Val,
uint64_t  Size,
Align  Alignment,
uint32_t  ElementSize,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Create and insert an element unordered-atomic memset of the region of memory starting at the given pointer to the given value.

If the pointer isn't an i8*, it will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.

Definition at line 614 of file IRBuilder.h.

References CreateElementUnorderedAtomicMemSet(), getInt64(), Ptr, and Size.

Referenced by CreateElementUnorderedAtomicMemSet().

◆ CreateElementUnorderedAtomicMemSet() [2/2]

CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemSet ( Value Ptr,
Value Val,
Value Size,
Align  Alignment,
uint32_t  ElementSize,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)

◆ CreateExactSDiv()

Value * llvm::IRBuilderBase::CreateExactSDiv ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1394 of file IRBuilder.h.

References CreateSDiv(), LHS, Name, and RHS.

Referenced by CreatePtrDiff().

◆ CreateExactUDiv()

Value * llvm::IRBuilderBase::CreateExactUDiv ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1381 of file IRBuilder.h.

References CreateUDiv(), LHS, Name, and RHS.

◆ CreateExtractElement() [1/2]

Value * llvm::IRBuilderBase::CreateExtractElement ( Value Vec,
uint64_t  Idx,
const Twine Name = "" 
)
inline

Definition at line 2450 of file IRBuilder.h.

References CreateExtractElement(), getInt64(), Idx, and Name.

◆ CreateExtractElement() [2/2]

Value * llvm::IRBuilderBase::CreateExtractElement ( Value Vec,
Value Idx,
const Twine Name = "" 
)
inline

◆ CreateExtractValue()

Value * llvm::IRBuilderBase::CreateExtractValue ( Value Agg,
ArrayRef< unsigned Idxs,
const Twine Name = "" 
)
inline

◆ CreateExtractVector()

CallInst * llvm::IRBuilderBase::CreateExtractVector ( Type DstType,
Value SrcVec,
Value Idx,
const Twine Name = "" 
)
inline

Create a call to the vector.extract intrinsic.

Definition at line 1031 of file IRBuilder.h.

References CreateIntrinsic(), llvm::Value::getType(), Idx, and Name.

Referenced by llvm::AArch64TargetLowering::lowerInterleavedLoad(), and llvm::AArch64TargetLowering::lowerInterleaveIntrinsicToStore().

◆ CreateFAdd()

Value * llvm::IRBuilderBase::CreateFAdd ( Value L,
Value R,
const Twine Name = "",
MDNode FPMD = nullptr 
)
inline

◆ CreateFAddFMF()

Value * llvm::IRBuilderBase::CreateFAddFMF ( Value L,
Value R,
Instruction FMFSource,
const Twine Name = "" 
)
inline

◆ CreateFAddReduce()

CallInst * IRBuilderBase::CreateFAddReduce ( Value Acc,
Value Src 
)

Create a sequential vector fadd reduction intrinsic of the source vector.

The first parameter is a scalar accumulator value. An unordered reduction can be created by adding the reassoc fast-math flag to the resulting sequential reduction.

Definition at line 417 of file IRBuilder.cpp.

References CreateCall(), llvm::Intrinsic::getDeclaration(), GetInsertBlock(), llvm::GlobalValue::getParent(), and llvm::BasicBlock::getParent().

Referenced by llvm::createSimpleTargetReduction().

◆ CreateFCmp()

Value * llvm::IRBuilderBase::CreateFCmp ( CmpInst::Predicate  P,
Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

◆ CreateFCmpOEQ()

Value * llvm::IRBuilderBase::CreateFCmpOEQ ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2264 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_OEQ, LHS, Name, and RHS.

◆ CreateFCmpOGE()

Value * llvm::IRBuilderBase::CreateFCmpOGE ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2274 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_OGE, LHS, Name, and RHS.

Referenced by optimizeSQRT().

◆ CreateFCmpOGT()

Value * llvm::IRBuilderBase::CreateFCmpOGT ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2269 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_OGT, LHS, Name, and RHS.

◆ CreateFCmpOLE()

Value * llvm::IRBuilderBase::CreateFCmpOLE ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2284 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_OLE, LHS, Name, and RHS.

◆ CreateFCmpOLT()

Value * llvm::IRBuilderBase::CreateFCmpOLT ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2279 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_OLT, LHS, Name, and RHS.

Referenced by emitRsqIEEE1ULP().

◆ CreateFCmpONE()

Value * llvm::IRBuilderBase::CreateFCmpONE ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2289 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_ONE, LHS, Name, and RHS.

◆ CreateFCmpORD()

Value * llvm::IRBuilderBase::CreateFCmpORD ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2294 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_ORD, LHS, Name, and RHS.

Referenced by optimizeSQRT().

◆ CreateFCmpS()

Value * llvm::IRBuilderBase::CreateFCmpS ( CmpInst::Predicate  P,
Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2359 of file IRBuilder.h.

References LHS, Name, P, and RHS.

◆ CreateFCmpUEQ()

Value * llvm::IRBuilderBase::CreateFCmpUEQ ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2304 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_UEQ, LHS, Name, and RHS.

◆ CreateFCmpUGE()

Value * llvm::IRBuilderBase::CreateFCmpUGE ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2314 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_UGE, LHS, Name, and RHS.

◆ CreateFCmpUGT()

Value * llvm::IRBuilderBase::CreateFCmpUGT ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2309 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_UGT, LHS, Name, and RHS.

◆ CreateFCmpULE()

Value * llvm::IRBuilderBase::CreateFCmpULE ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2324 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_ULE, LHS, Name, and RHS.

◆ CreateFCmpULT()

Value * llvm::IRBuilderBase::CreateFCmpULT ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2319 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_ULT, LHS, Name, and RHS.

◆ CreateFCmpUNE()

Value * llvm::IRBuilderBase::CreateFCmpUNE ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2329 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_UNE, LHS, Name, and RHS.

◆ CreateFCmpUNO()

Value * llvm::IRBuilderBase::CreateFCmpUNO ( Value LHS,
Value RHS,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

Definition at line 2299 of file IRBuilder.h.

References CreateFCmp(), llvm::CmpInst::FCMP_UNO, LHS, Name, and RHS.

◆ CreateFDiv()

Value * llvm::IRBuilderBase::CreateFDiv ( Value L,
Value R,
const Twine Name = "",
MDNode FPMD = nullptr 
)
inline

◆ CreateFDivFMF()

Value * llvm::IRBuilderBase::CreateFDivFMF ( Value L,
Value R,
Instruction FMFSource,
const Twine Name = "" 
)
inline

Copy fast-math-flags from an instruction rather than using the builder's default FMF.

Definition at line 1622 of file IRBuilder.h.

References CreateConstrainedFPBinOp(), FMF, llvm::IRBuilderFolder::FoldBinOpFMF(), Folder, llvm::Instruction::getFastMathFlags(), I, Insert(), IsFPConstrained, and Name.

Referenced by llvm::InstCombinerImpl::visitFAdd(), and llvm::InstCombinerImpl::visitFSub().

◆ CreateFence()

FenceInst * llvm::IRBuilderBase::CreateFence ( AtomicOrdering  Ordering,
SyncScope::ID  SSID = SyncScope::System,
const Twine Name = "" 
)
inline

◆ CreateFMul()

Value * llvm::IRBuilderBase::CreateFMul ( Value L,
Value R,
const Twine Name = "",
MDNode FPMD = nullptr 
)
inline

◆ CreateFMulFMF()

Value * llvm::IRBuilderBase::CreateFMulFMF ( Value L,
Value R,
Instruction FMFSource,
const Twine Name = "" 
)
inline

◆ CreateFMulReduce()

CallInst * IRBuilderBase::CreateFMulReduce ( Value Acc,
Value Src 
)

Create a sequential vector fmul reduction intrinsic of the source vector.

The first parameter is a scalar accumulator value. An unordered reduction can be created by adding the reassoc fast-math flag to the resulting sequential reduction.

Definition at line 425 of file IRBuilder.cpp.

References CreateCall(), llvm::Intrinsic::getDeclaration(), GetInsertBlock(), llvm::GlobalValue::getParent(), and llvm::BasicBlock::getParent().

Referenced by llvm::createSimpleTargetReduction().

◆ CreateFNeg()

Value * llvm::IRBuilderBase::CreateFNeg ( Value V,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)
inline

◆ CreateFNegFMF()

Value * llvm::IRBuilderBase::CreateFNegFMF ( Value V,
Instruction FMFSource,
const Twine Name = "" 
)
inline

Copy fast-math-flags from an instruction rather than using the builder's default FMF.

Definition at line 1739 of file IRBuilder.h.

References FMF, Folder, llvm::IRBuilderFolder::FoldUnOpFMF(), llvm::Instruction::getFastMathFlags(), Insert(), and Name.

Referenced by foldFDivPowDivisor(), llvm::InstCombinerImpl::visitCallInst(), and llvm::InstCombinerImpl::visitFNeg().

◆ CreateFPCast()

Value * llvm::IRBuilderBase::CreateFPCast ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

Definition at line 2200 of file IRBuilder.h.

References CreateCast(), llvm::Type::getScalarSizeInBits(), and Name.

Referenced by convertTo16Bit().

◆ CreateFPExt()

Value * llvm::IRBuilderBase::CreateFPExt ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateFPMaximumReduce()

CallInst * IRBuilderBase::CreateFPMaximumReduce ( Value Src)

Create a vector float maximum reduction intrinsic of the source vector.

This variant follows the NaN and signed zero semantic of llvm.maximum intrinsic.

Definition at line 473 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateFPMaxReduce()

CallInst * IRBuilderBase::CreateFPMaxReduce ( Value Src)

Create a vector float max reduction intrinsic of the source vector.

Definition at line 465 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateFPMinimumReduce()

CallInst * IRBuilderBase::CreateFPMinimumReduce ( Value Src)

Create a vector float minimum reduction intrinsic of the source vector.

This variant follows the NaN and signed zero semantic of llvm.minimum intrinsic.

Definition at line 477 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateFPMinReduce()

CallInst * IRBuilderBase::CreateFPMinReduce ( Value Src)

Create a vector float min reduction intrinsic of the source vector.

Definition at line 469 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateFPToSI()

Value * llvm::IRBuilderBase::CreateFPToSI ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

Definition at line 2063 of file IRBuilder.h.

References CreateCast(), CreateConstrainedFPCast(), IsFPConstrained, and Name.

Referenced by expandFPToI().

◆ CreateFPToUI()

Value * llvm::IRBuilderBase::CreateFPToUI ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateFPTrunc()

Value * llvm::IRBuilderBase::CreateFPTrunc ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateFree()

CallInst * IRBuilderBase::CreateFree ( Value Source,
ArrayRef< OperandBundleDef Bundles = std::nullopt 
)

Generate the IR for a call to the builtin free function.

CreateFree - Generate the IR for a call to the builtin free function.

Definition at line 353 of file IRBuilder.cpp.

References assert(), BB, CreateCall(), F, llvm::FunctionCallee::getCallee(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::PointerType::getUnqual(), and llvm::Type::getVoidTy().

◆ CreateFreeze()

Value * llvm::IRBuilderBase::CreateFreeze ( Value V,
const Twine Name = "" 
)
inline

◆ CreateFRem()

Value * llvm::IRBuilderBase::CreateFRem ( Value L,
Value R,
const Twine Name = "",
MDNode FPMD = nullptr 
)
inline

◆ CreateFRemFMF()

Value * llvm::IRBuilderBase::CreateFRemFMF ( Value L,
Value R,
Instruction FMFSource,
const Twine Name = "" 
)
inline

Copy fast-math-flags from an instruction rather than using the builder's default FMF.

Definition at line 1648 of file IRBuilder.h.

References CreateConstrainedFPBinOp(), FMF, llvm::IRBuilderFolder::FoldBinOpFMF(), Folder, llvm::Instruction::getFastMathFlags(), I, Insert(), IsFPConstrained, and Name.

Referenced by llvm::InstCombinerImpl::visitFPTrunc().

◆ CreateFSub()

Value * llvm::IRBuilderBase::CreateFSub ( Value L,
Value R,
const Twine Name = "",
MDNode FPMD = nullptr 
)
inline

◆ CreateFSubFMF()

Value * llvm::IRBuilderBase::CreateFSubFMF ( Value L,
Value R,
Instruction FMFSource,
const Twine Name = "" 
)
inline

Copy fast-math-flags from an instruction rather than using the builder's default FMF.

Definition at line 1568 of file IRBuilder.h.

References CreateConstrainedFPBinOp(), FMF, llvm::IRBuilderFolder::FoldBinOpFMF(), Folder, llvm::Instruction::getFastMathFlags(), I, Insert(), IsFPConstrained, and Name.

Referenced by factorizeFAddFSub(), factorizeLerp(), and llvm::InstCombinerImpl::visitFSub().

◆ CreateGCGetPointerBase()

CallInst * IRBuilderBase::CreateGCGetPointerBase ( Value DerivedPtr,
const Twine Name = "" 
)

Create a call to the experimental.gc.pointer.base intrinsic to get the base pointer for the specified derived pointer.

Definition at line 895 of file IRBuilder.cpp.

References BB, CreateCall(), llvm::Intrinsic::getDeclaration(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::Value::getType(), and Name.

◆ CreateGCGetPointerOffset()

CallInst * IRBuilderBase::CreateGCGetPointerOffset ( Value DerivedPtr,
const Twine Name = "" 
)

Create a call to the experimental.gc.get.pointer.offset intrinsic to get the offset of the specified derived pointer from its base.

Definition at line 904 of file IRBuilder.cpp.

References BB, CreateCall(), llvm::Intrinsic::getDeclaration(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::Value::getType(), and Name.

◆ CreateGCRelocate()

CallInst * IRBuilderBase::CreateGCRelocate ( Instruction Statepoint,
int  BaseOffset,
int  DerivedOffset,
Type ResultType,
const Twine Name = "" 
)

Create a call to the experimental.gc.relocate intrinsics to project the relocated value of one pointer from the statepoint.

Definition at line 883 of file IRBuilder.cpp.

References BB, CreateCall(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), and Name.

◆ CreateGCResult()

CallInst * IRBuilderBase::CreateGCResult ( Instruction Statepoint,
Type ResultType,
const Twine Name = "" 
)

Create a call to the experimental.gc.result intrinsic to extract the result from a call wrapped in a statepoint.

Definition at line 872 of file IRBuilder.cpp.

References BB, CreateCall(), llvm::Intrinsic::getDeclaration(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), and Name.

Referenced by makeStatepointExplicitImpl().

◆ CreateGCStatepointCall() [1/3]

CallInst * IRBuilderBase::CreateGCStatepointCall ( uint64_t  ID,
uint32_t  NumPatchBytes,
FunctionCallee  ActualCallee,
ArrayRef< Use CallArgs,
std::optional< ArrayRef< Value * > >  DeoptArgs,
ArrayRef< Value * >  GCArgs,
const Twine Name = "" 
)

Conveninence function for the common case when CallArgs are filled in using ArrayRef(CS.arg_begin(), CS.arg_end()); Use needs to be .get()'ed to get the Value pointer.

Definition at line 803 of file IRBuilder.cpp.

References Name, and llvm::None.

◆ CreateGCStatepointCall() [2/3]

CallInst * IRBuilderBase::CreateGCStatepointCall ( uint64_t  ID,
uint32_t  NumPatchBytes,
FunctionCallee  ActualCallee,
ArrayRef< Value * >  CallArgs,
std::optional< ArrayRef< Value * > >  DeoptArgs,
ArrayRef< Value * >  GCArgs,
const Twine Name = "" 
)

Create a call to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.

Definition at line 783 of file IRBuilder.cpp.

References Name, and llvm::None.

Referenced by makeStatepointExplicitImpl().

◆ CreateGCStatepointCall() [3/3]

CallInst * IRBuilderBase::CreateGCStatepointCall ( uint64_t  ID,
uint32_t  NumPatchBytes,
FunctionCallee  ActualCallee,
uint32_t  Flags,
ArrayRef< Value * >  CallArgs,
std::optional< ArrayRef< Use > >  TransitionArgs,
std::optional< ArrayRef< Use > >  DeoptArgs,
ArrayRef< Value * >  GCArgs,
const Twine Name = "" 
)

Create a call to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.

Definition at line 792 of file IRBuilder.cpp.

References Name.

◆ CreateGCStatepointInvoke() [1/3]

InvokeInst * IRBuilderBase::CreateGCStatepointInvoke ( uint64_t  ID,
uint32_t  NumPatchBytes,
FunctionCallee  ActualInvokee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
ArrayRef< Use InvokeArgs,
std::optional< ArrayRef< Value * > >  DeoptArgs,
ArrayRef< Value * >  GCArgs,
const Twine Name = "" 
)

Definition at line 861 of file IRBuilder.cpp.

References Name, and llvm::None.

◆ CreateGCStatepointInvoke() [2/3]

InvokeInst * IRBuilderBase::CreateGCStatepointInvoke ( uint64_t  ID,
uint32_t  NumPatchBytes,
FunctionCallee  ActualInvokee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
ArrayRef< Value * >  InvokeArgs,
std::optional< ArrayRef< Value * > >  DeoptArgs,
ArrayRef< Value * >  GCArgs,
const Twine Name = "" 
)

Create an invoke to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.

Definition at line 839 of file IRBuilder.cpp.

References Name, and llvm::None.

Referenced by makeStatepointExplicitImpl().

◆ CreateGCStatepointInvoke() [3/3]

InvokeInst * IRBuilderBase::CreateGCStatepointInvoke ( uint64_t  ID,
uint32_t  NumPatchBytes,
FunctionCallee  ActualInvokee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
uint32_t  Flags,
ArrayRef< Value * >  InvokeArgs,
std::optional< ArrayRef< Use > >  TransitionArgs,
std::optional< ArrayRef< Use > >  DeoptArgs,
ArrayRef< Value * >  GCArgs,
const Twine Name = "" 
)

Create an invoke to the experimental.gc.statepoint intrinsic to start a new statepoint sequence.

Definition at line 850 of file IRBuilder.cpp.

References Name.

◆ CreateGEP()

Value * llvm::IRBuilderBase::CreateGEP ( Type Ty,
Value Ptr,
ArrayRef< Value * >  IdxList,
const Twine Name = "",
bool  IsInBounds = false 
)
inline

◆ CreateGlobalString()

GlobalVariable * IRBuilderBase::CreateGlobalString ( StringRef  Str,
const Twine Name = "",
unsigned  AddressSpace = 0,
Module M = nullptr 
)

Make a new global variable with initializer type i8*.

CreateGlobalString - Make a new global variable with an initializer that has array of i8 type filled in with the nul terminated string value specified.

Make a new global variable with an initializer that has array of i8 type filled in with the null terminated string value specified. The new global variable will be marked mergable with any others of the same contents. If Name is specified, it is the name of the global variable created.

If no module is given via M, it is take from the insertion point basic block.

If Name is specified, it is the name of the global variable created.

Definition at line 43 of file IRBuilder.cpp.

References BB, Context, llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::ConstantDataArray::getString(), llvm::Value::getType(), llvm::GlobalValue::Global, Name, llvm::GlobalValue::NotThreadLocal, and llvm::GlobalValue::PrivateLinkage.

Referenced by CreateGlobalStringPtr().

◆ CreateGlobalStringPtr()

Constant * llvm::IRBuilderBase::CreateGlobalStringPtr ( StringRef  Str,
const Twine Name = "",
unsigned  AddressSpace = 0,
Module M = nullptr 
)
inline

Same as CreateGlobalString, but return a pointer with "i8*" type instead of a pointer to array of i8.

If no module is given via M, it is take from the insertion point basic block.

Definition at line 1992 of file IRBuilder.h.

References Context, CreateGlobalString(), llvm::ConstantExpr::getInBoundsGetElementPtr(), llvm::Type::getInt32Ty(), llvm::GlobalValue::getValueType(), and Name.

Referenced by llvm::OpenMPIRBuilder::getOrCreateSrcLocStr().

◆ CreateICmp()

Value * llvm::IRBuilderBase::CreateICmp ( CmpInst::Predicate  P,
Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 2334 of file IRBuilder.h.

References Folder, llvm::IRBuilderFolder::FoldICmp(), Insert(), LHS, Name, P, and RHS.

Referenced by buildNew(), llvm::OpenMPIRBuilder::createCanonicalLoop(), CreateCmp(), CreateICmpEQ(), CreateICmpNE(), CreateICmpSGE(), CreateICmpSGT(), CreateICmpSLE(), CreateICmpSLT(), CreateICmpUGE(), CreateICmpUGT(), CreateICmpULE(), CreateICmpULT(), createInvariantCond(), llvm::InnerLoopVectorizer::emitIterationCountCheck(), llvm::EpilogueVectorizerMainLoop::emitIterationCountCheck(), llvm::EpilogueVectorizerEpilogueLoop::emitMinimumVectorEpilogueIterCountCheck(), llvm::VPWidenRecipe::execute(), llvm::SCEVExpander::expandComparePredicate(), foldAndOrOfICmpEqConstantAndICmp(), foldAndOrOfICmpsWithConstEq(), foldClampRangeOfTwo(), foldCtpop(), llvm::InstCombinerImpl::foldGEPICmp(), llvm::InstCombinerImpl::foldICmpDivConstant(), llvm::InstCombinerImpl::foldICmpOrConstant(), foldICmpOrXorSubChain(), llvm::InstCombinerImpl::foldICmpSelectConstant(), llvm::InstCombinerImpl::foldICmpUsingBoolRange(), foldICmpWithLowBitMaskedVal(), foldICmpWithTruncSignExtendedVal(), foldLogOpOfMaskedICmps(), foldLogOpOfMaskedICmps_NotAllZeros_BMask_Mixed(), foldNegativePower2AndShiftedMask(), llvm::InstCombinerImpl::foldSelectICmp(), llvm::InstCombinerImpl::FoldShiftByConstant(), foldShiftIntoShiftInAnotherHandOfAndInICmp(), llvm::SCEVExpander::generateOverflowCheck(), generateReproducer(), getNewICmpValue(), hoistMinMax(), llvm::InstCombinerImpl::insertRangeTest(), reassociateMinMaxWithConstants(), ReduceLoopStrength(), llvm::InstCombinerImpl::simplifyRangeCheck(), sinkMinMaxInBB(), llvm::splitLoopBound(), llvm::InstCombinerImpl::tryFoldInstWithCtpopWithNot(), llvm::UnrollRuntimeLoopRemainder(), llvm::UpgradeIntrinsicCall(), upgradeMaskedCompare(), upgradeX86vpcom(), llvm::InstCombinerImpl::visitICmpInst(), and llvm::InstCombinerImpl::visitOr().

◆ CreateICmpEQ()

Value * llvm::IRBuilderBase::CreateICmpEQ ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateICmpNE()

Value * llvm::IRBuilderBase::CreateICmpNE ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateICmpSGE()

Value * llvm::IRBuilderBase::CreateICmpSGE ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 2252 of file IRBuilder.h.

References CreateICmp(), llvm::CmpInst::ICMP_SGE, LHS, Name, and RHS.

Referenced by llvm::UpgradeIntrinsicCall().

◆ CreateICmpSGT()

Value * llvm::IRBuilderBase::CreateICmpSGT ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateICmpSLE()

Value * llvm::IRBuilderBase::CreateICmpSLE ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 2260 of file IRBuilder.h.

References CreateICmp(), llvm::CmpInst::ICMP_SLE, LHS, Name, and RHS.

Referenced by llvm::buildAtomicRMWValue(), and llvm::UpgradeIntrinsicCall().

◆ CreateICmpSLT()

Value * llvm::IRBuilderBase::CreateICmpSLT ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateICmpUGE()

Value * llvm::IRBuilderBase::CreateICmpUGE ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateICmpUGT()

Value * llvm::IRBuilderBase::CreateICmpUGT ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateICmpULE()

Value * llvm::IRBuilderBase::CreateICmpULE ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 2244 of file IRBuilder.h.

References CreateICmp(), llvm::CmpInst::ICMP_ULE, LHS, Name, and RHS.

Referenced by llvm::buildAtomicRMWValue(), and llvm::UpgradeIntrinsicCall().

◆ CreateICmpULT()

Value * llvm::IRBuilderBase::CreateICmpULT ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

◆ CreateInBoundsGEP()

Value * llvm::IRBuilderBase::CreateInBoundsGEP ( Type Ty,
Value Ptr,
ArrayRef< Value * >  IdxList,
const Twine Name = "" 
)
inline

◆ CreateInBoundsPtrAdd()

Value * llvm::IRBuilderBase::CreateInBoundsPtrAdd ( Value Ptr,
Value Offset,
const Twine Name = "" 
)
inline

Definition at line 1982 of file IRBuilder.h.

References CreateGEP(), getInt8Ty(), Name, llvm::Offset, and Ptr.

◆ CreateIndirectBr()

IndirectBrInst * llvm::IRBuilderBase::CreateIndirectBr ( Value Addr,
unsigned  NumDests = 10 
)
inline

Create an indirect branch instruction with the specified address operand, with an optional hint for the number of destinations that will be added (for efficient allocation).

Definition at line 1147 of file IRBuilder.h.

References Addr, llvm::IndirectBrInst::Create(), and Insert().

◆ CreateInsertElement() [1/4]

Value * llvm::IRBuilderBase::CreateInsertElement ( Type VecTy,
Value NewElt,
uint64_t  Idx,
const Twine Name = "" 
)
inline

Definition at line 2460 of file IRBuilder.h.

References CreateInsertElement(), llvm::PoisonValue::get(), Idx, and Name.

◆ CreateInsertElement() [2/4]

Value * llvm::IRBuilderBase::CreateInsertElement ( Type VecTy,
Value NewElt,
Value Idx,
const Twine Name = "" 
)
inline

◆ CreateInsertElement() [3/4]

Value * llvm::IRBuilderBase::CreateInsertElement ( Value Vec,
Value NewElt,
uint64_t  Idx,
const Twine Name = "" 
)
inline

Definition at line 2472 of file IRBuilder.h.

References CreateInsertElement(), getInt64(), Idx, and Name.

◆ CreateInsertElement() [4/4]

Value * llvm::IRBuilderBase::CreateInsertElement ( Value Vec,
Value NewElt,
Value Idx,
const Twine Name = "" 
)
inline

◆ CreateInsertValue()

Value * llvm::IRBuilderBase::CreateInsertValue ( Value Agg,
Value Val,
ArrayRef< unsigned Idxs,
const Twine Name = "" 
)
inline

◆ CreateInsertVector()

CallInst * llvm::IRBuilderBase::CreateInsertVector ( Type DstType,
Value SrcVec,
Value SubVec,
Value Idx,
const Twine Name = "" 
)
inline

◆ CreateIntCast() [1/2]

Value * llvm::IRBuilderBase::CreateIntCast ( Value ,
Type ,
const char  
)
delete

◆ CreateIntCast() [2/2]

Value * llvm::IRBuilderBase::CreateIntCast ( Value V,
Type DestTy,
bool  isSigned,
const Twine Name = "" 
)
inline

◆ CreateIntMaxReduce()

CallInst * IRBuilderBase::CreateIntMaxReduce ( Value Src,
bool  IsSigned = false 
)

Create a vector integer max reduction intrinsic of the source vector.

Definition at line 453 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateIntMinReduce()

CallInst * IRBuilderBase::CreateIntMinReduce ( Value Src,
bool  IsSigned = false 
)

Create a vector integer min reduction intrinsic of the source vector.

Definition at line 459 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateIntrinsic() [1/2]

CallInst * IRBuilderBase::CreateIntrinsic ( Intrinsic::ID  ID,
ArrayRef< Type * >  Types,
ArrayRef< Value * >  Args,
Instruction FMFSource = nullptr,
const Twine Name = "" 
)

Create a call to intrinsic ID with Args, mangled using Types.

If FMFSource is provided, copy fast-math-flags from that instruction to the intrinsic.

Definition at line 930 of file IRBuilder.cpp.

References BB, llvm::Intrinsic::getDeclaration(), llvm::BasicBlock::getModule(), and Name.

Referenced by CreateArithmeticFence(), CreateConstrainedFPBinOp(), CreateConstrainedFPCast(), CreateConstrainedFPCmp(), CreateConstrainedFPUnroundedBinOp(), CreateExtractVector(), CreateInsertVector(), createMaskInstrs(), llvm::createMinMaxOp(), CreateStackRestore(), CreateStackSave(), CreateStepVector(), CreateThreadLocalAddress(), createTileStore(), llvm::SITargetLowering::emitExpandAtomicRMW(), foldFDivPowDivisor(), llvm::InstCombinerImpl::foldFMulReassoc(), llvm::InstCombinerImpl::foldICmpEquality(), foldICmpIntrinsicWithIntrinsic(), llvm::InstCombinerImpl::foldSelectOpOp(), foldShuffledIntrinsicOperands(), foldSubOfMinMax(), InsertIntrinsicCalls(), llvm::GCNTTIImpl::instCombineIntrinsic(), llvm::ARMTTIImpl::instCombineIntrinsic(), instCombineRDFFR(), instCombineSVECmpNE(), instCombineSVECondLast(), instCombineSVELast(), instCombineSVEPTest(), instCombineSVESDIV(), instCombineSVESrshl(), instCombineSVEVectorFuseMulAddSub(), interleaveVectors(), llvm::AArch64TargetLowering::lowerInterleavedLoad(), llvm::AArch64TargetLowering::lowerInterleavedStore(), lowerIntrinsicToFunction(), lowerKernelArguments(), reassociateMinMaxWithConstants(), ReduceSwitchRange(), replaceWithTileLoad(), simplifySwitchOfPowersOfTwo(), simplifyX86addcarry(), tryCombineFromSVBoolBinOp(), llvm::InstCombinerImpl::tryFoldInstWithCtpopWithNot(), llvm::InnerLoopVectorizer::vectorizeInterleaveGroup(), llvm::InstCombinerImpl::visitAdd(), llvm::InstCombinerImpl::visitCallInst(), llvm::InstCombinerImpl::visitFAdd(), llvm::InstCombinerImpl::visitFDiv(), llvm::InstCombinerImpl::visitFMul(), llvm::InstCombinerImpl::visitFSub(), llvm::InstCombinerImpl::visitSub(), and llvm::InstCombinerImpl::visitTrunc().

◆ CreateIntrinsic() [2/2]

CallInst * IRBuilderBase::CreateIntrinsic ( Type RetTy,
Intrinsic::ID  ID,
ArrayRef< Value * >  Args,
Instruction FMFSource = nullptr,
const Twine Name = "" 
)

◆ CreateIntToPtr()

Value * llvm::IRBuilderBase::CreateIntToPtr ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreateInvariantStart()

CallInst * IRBuilderBase::CreateInvariantStart ( Value Ptr,
ConstantInt Size = nullptr 
)

Create a call to invariant.start intrinsic.

If the pointer isn't i8* it will be converted.

Definition at line 511 of file IRBuilder.cpp.

References assert(), BB, CreateCall(), llvm::Intrinsic::getDeclaration(), getInt64(), getInt64Ty(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), Ptr, and Size.

◆ CreateInvoke() [1/4]

InvokeInst * llvm::IRBuilderBase::CreateInvoke ( FunctionCallee  Callee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
ArrayRef< Value * >  Args,
ArrayRef< OperandBundleDef OpBundles,
const Twine Name = "" 
)
inline

Definition at line 1174 of file IRBuilder.h.

References CreateInvoke(), and Name.

◆ CreateInvoke() [2/4]

InvokeInst * llvm::IRBuilderBase::CreateInvoke ( FunctionCallee  Callee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "" 
)
inline

Definition at line 1182 of file IRBuilder.h.

References CreateInvoke(), and Name.

◆ CreateInvoke() [3/4]

InvokeInst * llvm::IRBuilderBase::CreateInvoke ( FunctionType Ty,
Value Callee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
ArrayRef< Value * >  Args,
ArrayRef< OperandBundleDef OpBundles,
const Twine Name = "" 
)
inline

Create an invoke instruction.

Definition at line 1152 of file IRBuilder.h.

References llvm::InvokeInst::Create(), Insert(), IsFPConstrained, Name, and setConstrainedFPCallAttr().

Referenced by CreateGCStatepointInvokeCommon(), and CreateInvoke().

◆ CreateInvoke() [4/4]

InvokeInst * llvm::IRBuilderBase::CreateInvoke ( FunctionType Ty,
Value Callee,
BasicBlock NormalDest,
BasicBlock UnwindDest,
ArrayRef< Value * >  Args = std::nullopt,
const Twine Name = "" 
)
inline

◆ createIsFPClass()

Value * IRBuilderBase::createIsFPClass ( Value FPNum,
unsigned  Test 
)

◆ CreateIsNeg()

Value * llvm::IRBuilderBase::CreateIsNeg ( Value Arg,
const Twine Name = "" 
)
inline

◆ CreateIsNotNeg()

Value * llvm::IRBuilderBase::CreateIsNotNeg ( Value Arg,
const Twine Name = "" 
)
inline

◆ CreateIsNotNull()

Value * llvm::IRBuilderBase::CreateIsNotNull ( Value Arg,
const Twine Name = "" 
)
inline

◆ CreateIsNull()

Value * llvm::IRBuilderBase::CreateIsNull ( Value Arg,
const Twine Name = "" 
)
inline

◆ CreateLandingPad()

LandingPadInst * llvm::IRBuilderBase::CreateLandingPad ( Type Ty,
unsigned  NumClauses,
const Twine Name = "" 
)
inline

Definition at line 2513 of file IRBuilder.h.

References llvm::LandingPadInst::Create(), Insert(), and Name.

◆ CreateLaunderInvariantGroup()

Value * IRBuilderBase::CreateLaunderInvariantGroup ( Value Ptr)

Create a launder.invariant.group intrinsic call.

If Ptr type is different from pointer to i8, it's casted to pointer to i8 in the same address space before call and casted back to Ptr type after call.

Definition at line 1135 of file IRBuilder.cpp.

References assert(), BB, CreateCall(), llvm::Intrinsic::getDeclaration(), llvm::Function::getFunctionType(), llvm::FunctionType::getParamType(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), llvm::Function::getReturnType(), and Ptr.

Referenced by simplifyInvariantGroupIntrinsic().

◆ CreateLifetimeEnd()

CallInst * IRBuilderBase::CreateLifetimeEnd ( Value Ptr,
ConstantInt Size = nullptr 
)

Create a lifetime.end intrinsic.

If the pointer isn't i8* it will be converted.

Definition at line 496 of file IRBuilder.cpp.

References assert(), BB, CreateCall(), llvm::Intrinsic::getDeclaration(), getInt64(), getInt64Ty(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), Ptr, and Size.

Referenced by llvm::InlineFunction().

◆ CreateLifetimeStart()

CallInst * IRBuilderBase::CreateLifetimeStart ( Value Ptr,
ConstantInt Size = nullptr 
)

Create a lifetime.start intrinsic.

If the pointer isn't i8* it will be converted.

Definition at line 481 of file IRBuilder.cpp.

References assert(), BB, CreateCall(), llvm::Intrinsic::getDeclaration(), getInt64(), getInt64Ty(), llvm::GlobalValue::getParent(), llvm::BasicBlock::getParent(), Ptr, and Size.

Referenced by llvm::InlineFunction().

◆ CreateLoad() [1/3]

LoadInst * llvm::IRBuilderBase::CreateLoad ( Type Ty,
Value Ptr,
bool  isVolatile,
const Twine Name = "" 
)
inline

Definition at line 1797 of file IRBuilder.h.

References CreateAlignedLoad(), Name, and Ptr.

◆ CreateLoad() [2/3]

LoadInst * llvm::IRBuilderBase::CreateLoad ( Type Ty,
Value Ptr,
const char Name 
)
inline

◆ CreateLoad() [3/3]

LoadInst * llvm::IRBuilderBase::CreateLoad ( Type Ty,
Value Ptr,
const Twine Name = "" 
)
inline

Definition at line 1793 of file IRBuilder.h.

References CreateAlignedLoad(), Name, and Ptr.

◆ CreateLogicalAnd()

Value * llvm::IRBuilderBase::CreateLogicalAnd ( Value Cond1,
Value Cond2,
const Twine Name = "" 
)
inline

◆ CreateLogicalOp()

Value * llvm::IRBuilderBase::CreateLogicalOp ( Instruction::BinaryOps  Opc,
Value Cond1,
Value Cond2,
const Twine Name = "" 
)
inline

◆ CreateLogicalOr() [1/2]

Value * llvm::IRBuilderBase::CreateLogicalOr ( ArrayRef< Value * >  Ops)
inline

◆ CreateLogicalOr() [2/2]

Value * llvm::IRBuilderBase::CreateLogicalOr ( Value Cond1,
Value Cond2,
const Twine Name = "" 
)
inline

◆ CreateLShr() [1/3]

Value * llvm::IRBuilderBase::CreateLShr ( Value LHS,
const APInt RHS,
const Twine Name = "",
bool  isExact = false 
)
inline

Definition at line 1440 of file IRBuilder.h.

References CreateLShr(), LHS, Name, and RHS.

◆ CreateLShr() [2/3]

Value * llvm::IRBuilderBase::CreateLShr ( Value LHS,
uint64_t  RHS,
const Twine Name = "",
bool  isExact = false 
)
inline

Definition at line 1445 of file IRBuilder.h.

References CreateLShr(), LHS, Name, and RHS.

◆ CreateLShr() [3/3]

Value * llvm::IRBuilderBase::CreateLShr ( Value LHS,
Value RHS,
const Twine Name = "",
bool  isExact = false 
)
inline

◆ CreateMalloc() [1/2]

CallInst * IRBuilderBase::CreateMalloc ( Type IntPtrTy,
Type AllocTy,
Value AllocSize,
Value ArraySize,
ArrayRef< OperandBundleDef OpB,
Function MallocF = nullptr,
const Twine Name = "" 
)

◆ CreateMalloc() [2/2]

CallInst * IRBuilderBase::CreateMalloc ( Type IntPtrTy,
Type AllocTy,
Value AllocSize,
Value ArraySize,
Function MallocF = nullptr,
const Twine Name = "" 
)

CreateMalloc - Generate the IR for a call to malloc:

  1. Compute the malloc call's argument as the specified type's size, possibly multiplied by the array size if the array size is not constant 1.
  2. Call malloc with that argument.

Definition at line 344 of file IRBuilder.cpp.

References CreateMalloc(), and Name.

◆ CreateMaskedCompressStore()

CallInst * IRBuilderBase::CreateMaskedCompressStore ( Value Val,
Value Ptr,
Value Mask = nullptr 
)

Create a call to Masked Compress Store intrinsic.

Create a call to Masked Compress Store intrinsic Val - data to be stored, Ptr - base pointer for the store Mask - vector of booleans which indicates what vector lanes should be accessed in memory.

Definition at line 704 of file IRBuilder.cpp.

References assert(), llvm::Value::getType(), llvm::Type::isVectorTy(), and Ptr.

◆ CreateMaskedExpandLoad()

CallInst * IRBuilderBase::CreateMaskedExpandLoad ( Type Ty,
Value Ptr,
Value Mask = nullptr,
Value PassThru = nullptr,
const Twine Name = "" 
)

Create a call to Masked Expand Load intrinsic.

Create a call to Masked Expand Load intrinsic Ty - vector type to load Ptr - base pointer for the load Mask - vector of booleans which indicates what vector lanes should be accessed in memory PassThru - pass-through value that is used to fill the masked-off lanes of the result Name - name of the result variable.

Definition at line 686 of file IRBuilder.cpp.

References assert(), llvm::PoisonValue::get(), llvm::Type::isVectorTy(), Name, and Ptr.

◆ CreateMaskedGather()

CallInst * IRBuilderBase::CreateMaskedGather ( Type Ty,
Value Ptrs,
Align  Alignment,
Value Mask = nullptr,
Value PassThru = nullptr,
const Twine Name = "" 
)

Create a call to Masked Gather intrinsic.

Create a call to a Masked Gather intrinsic.

Ty - vector type to gather Ptrs - vector of pointers for loading Align - alignment for one element Mask - vector of booleans which indicates what vector lanes should be accessed in memory PassThru - pass-through value that is used to fill the masked-off lanes of the result Name - name of the result variable

Definition at line 630 of file IRBuilder.cpp.

References assert(), llvm::PoisonValue::get(), getAllOnesMask(), getInt32(), llvm::Value::getType(), Name, and llvm::Align::value().

◆ CreateMaskedLoad()

CallInst * IRBuilderBase::CreateMaskedLoad ( Type Ty,
Value Ptr,
Align  Alignment,
Value Mask,
Value PassThru = nullptr,
const Twine Name = "" 
)

Create a call to Masked Load intrinsic.

Create a call to a Masked Load intrinsic.

Ty - vector type to load Ptr - base pointer for the load Alignment - alignment of the source location Mask - vector of booleans which indicates what vector lanes should be accessed in memory PassThru - pass-through value that is used to fill the masked-off lanes of the result Name - name of the result variable

Definition at line 578 of file IRBuilder.cpp.

References assert(), llvm::PoisonValue::get(), getInt32(), llvm::Type::isVectorTy(), Name, Ptr, and llvm::Align::value().

Referenced by instCombineLD1GatherIndex(), instCombineSVELD1(), simplifyX86MaskedLoad(), upgradeMaskedLoad(), and llvm::InnerLoopVectorizer::vectorizeInterleaveGroup().

◆ CreateMaskedScatter()

CallInst * IRBuilderBase::CreateMaskedScatter ( Value Data,
Value Ptrs,
Align  Alignment,
Value Mask = nullptr 
)

Create a call to Masked Scatter intrinsic.

Create a call to a Masked Scatter intrinsic.

Data - data to be stored, Ptrs - the vector of pointers, where the Data elements should be stored Align - alignment for one element Mask - vector of booleans which indicates what vector lanes should be accessed in memory

Definition at line 661 of file IRBuilder.cpp.

References llvm::Data, getAllOnesMask(), getInt32(), llvm::Value::getType(), and llvm::Align::value().

◆ CreateMaskedStore()

CallInst * IRBuilderBase::CreateMaskedStore ( Value Val,
Value Ptr,
Align  Alignment,
Value Mask 
)

Create a call to Masked Store intrinsic.

Create a call to a Masked Store intrinsic.

Val - data to be stored, Ptr - base pointer for the store Alignment - alignment of the destination location Mask - vector of booleans which indicates what vector lanes should be accessed in memory

Definition at line 598 of file IRBuilder.cpp.

References assert(), getInt32(), llvm::Value::getType(), llvm::Type::isVectorTy(), Ptr, and llvm::Align::value().

Referenced by instCombineST1ScatterIndex(), instCombineSVEST1(), simplifyX86MaskedStore(), upgradeMaskedStore(), and llvm::InnerLoopVectorizer::vectorizeInterleaveGroup().

◆ CreateMaximum()

CallInst * llvm::IRBuilderBase::CreateMaximum ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Create call to the maximum intrinsic.

Definition at line 1011 of file IRBuilder.h.

References CreateBinaryIntrinsic(), LHS, Name, and RHS.

◆ CreateMaxNum()

CallInst * llvm::IRBuilderBase::CreateMaxNum ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Create call to the maxnum intrinsic.

Definition at line 996 of file IRBuilder.h.

References CreateBinaryIntrinsic(), CreateConstrainedFPUnroundedBinOp(), IsFPConstrained, LHS, Name, and RHS.

Referenced by llvm::buildAtomicRMWValue(), and llvm::GCNTTIImpl::instCombineIntrinsic().

◆ CreateMemCpy() [1/2]

CallInst * llvm::IRBuilderBase::CreateMemCpy ( Value Dst,
MaybeAlign  DstAlign,
Value Src,
MaybeAlign  SrcAlign,
uint64_t  Size,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode TBAAStructTag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Create and insert a memcpy between the specified pointers.

If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.

Definition at line 653 of file IRBuilder.h.

References CreateMemCpy(), getInt64(), and Size.

Referenced by callBufferedPrintfArgPush(), CreateMemCpy(), llvm::OpenMPIRBuilder::createTask(), llvm::OpenMPIRBuilder::emitOffloadingArrays(), and HandleByValArgumentInit().

◆ CreateMemCpy() [2/2]

CallInst * llvm::IRBuilderBase::CreateMemCpy ( Value Dst,
MaybeAlign  DstAlign,
Value Src,
MaybeAlign  SrcAlign,
Value Size,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode TBAAStructTag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Definition at line 670 of file IRBuilder.h.

References CreateMemTransferInst(), and Size.

◆ CreateMemCpyInline()

CallInst * llvm::IRBuilderBase::CreateMemCpyInline ( Value Dst,
MaybeAlign  DstAlign,
Value Src,
MaybeAlign  SrcAlign,
Value Size,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode TBAAStructTag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Definition at line 682 of file IRBuilder.h.

References CreateMemTransferInst(), and Size.

◆ CreateMemMove() [1/2]

CallInst * llvm::IRBuilderBase::CreateMemMove ( Value Dst,
MaybeAlign  DstAlign,
Value Src,
MaybeAlign  SrcAlign,
uint64_t  Size,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Definition at line 705 of file IRBuilder.h.

References CreateMemMove(), getInt64(), and Size.

Referenced by CreateMemMove().

◆ CreateMemMove() [2/2]

CallInst * llvm::IRBuilderBase::CreateMemMove ( Value Dst,
MaybeAlign  DstAlign,
Value Src,
MaybeAlign  SrcAlign,
Value Size,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Definition at line 714 of file IRBuilder.h.

References CreateMemTransferInst(), and Size.

◆ CreateMemSet() [1/2]

CallInst * llvm::IRBuilderBase::CreateMemSet ( Value Ptr,
Value Val,
uint64_t  Size,
MaybeAlign  Align,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)
inline

Create and insert a memset to the specified pointer and the specified value.

If the pointer isn't an i8*, it will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.

Definition at line 589 of file IRBuilder.h.

References CreateMemSet(), getInt64(), Ptr, and Size.

Referenced by CreateMemSet(), lowerIntrinsicToFunction(), and OptimizeGlobalAddressOfAllocation().

◆ CreateMemSet() [2/2]

CallInst * IRBuilderBase::CreateMemSet ( Value Ptr,
Value Val,
Value Size,
MaybeAlign  Align,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)

◆ CreateMemSetInline()

CallInst * IRBuilderBase::CreateMemSetInline ( Value Dst,
MaybeAlign  DstAlign,
Value Val,
Value Size,
bool  IsVolatile = false,
MDNode TBAATag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)

◆ CreateMemTransferInst()

CallInst * IRBuilderBase::CreateMemTransferInst ( Intrinsic::ID  IntrID,
Value Dst,
MaybeAlign  DstAlign,
Value Src,
MaybeAlign  SrcAlign,
Value Size,
bool  isVolatile = false,
MDNode TBAATag = nullptr,
MDNode TBAAStructTag = nullptr,
MDNode ScopeTag = nullptr,
MDNode NoAliasTag = nullptr 
)

◆ CreateMinimum()

CallInst * llvm::IRBuilderBase::CreateMinimum ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Create call to the minimum intrinsic.

Definition at line 1006 of file IRBuilder.h.

References CreateBinaryIntrinsic(), LHS, Name, and RHS.

◆ CreateMinNum()

CallInst * llvm::IRBuilderBase::CreateMinNum ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Create call to the minnum intrinsic.

Definition at line 986 of file IRBuilder.h.

References CreateBinaryIntrinsic(), CreateConstrainedFPUnroundedBinOp(), IsFPConstrained, LHS, Name, and RHS.

Referenced by llvm::buildAtomicRMWValue(), and llvm::GCNTTIImpl::instCombineIntrinsic().

◆ CreateMul()

Value * llvm::IRBuilderBase::CreateMul ( Value LHS,
Value RHS,
const Twine Name = "",
bool  HasNUW = false,
bool  HasNSW = false 
)
inline

◆ CreateMulReduce()

CallInst * IRBuilderBase::CreateMulReduce ( Value Src)

Create a vector int mul reduction intrinsic of the source vector.

Definition at line 437 of file IRBuilder.cpp.

Referenced by llvm::createSimpleTargetReduction().

◆ CreateNAryOp()

Value * IRBuilderBase::CreateNAryOp ( unsigned  Opc,
ArrayRef< Value * >  Ops,
const Twine Name = "",
MDNode FPMathTag = nullptr 
)

Create either a UnaryOperator or BinaryOperator depending on Opc.

Correct number of operands must be passed accordingly.

Definition at line 1003 of file IRBuilder.cpp.

References assert(), CreateBinOp(), CreateUnOp(), llvm::Instruction::isBinaryOp(), llvm::Instruction::isUnaryOp(), llvm_unreachable, Name, and llvm::ArrayRef< T >::size().

Referenced by llvm::VPWidenRecipe::execute().

◆ CreateNeg()

Value * llvm::IRBuilderBase::CreateNeg ( Value V,
const Twine Name = "",
bool  HasNUW = false,
bool  HasNSW = false 
)
inline

◆ CreateNoAliasScopeDeclaration() [1/2]

Instruction * llvm::IRBuilderBase::CreateNoAliasScopeDeclaration ( MDNode ScopeTag)
inline

◆ CreateNoAliasScopeDeclaration() [2/2]

Instruction * IRBuilderBase::CreateNoAliasScopeDeclaration ( Value Scope)

Create a llvm.experimental.noalias.scope.decl intrinsic call.

Definition at line 562 of file IRBuilder.cpp.

References BB, CreateCall(), llvm::Intrinsic::getDeclaration(), and llvm::BasicBlock::getModule().

Referenced by AddAliasScopeMetadata(), and CreateNoAliasScopeDeclaration().

◆ CreateNot()

Value * llvm::IRBuilderBase::CreateNot ( Value V,
const Twine Name = "" 
)
inline

◆ CreateNSWAdd()

Value * llvm::IRBuilderBase::CreateNSWAdd ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1330 of file IRBuilder.h.

References CreateAdd(), LHS, Name, and RHS.

Referenced by rewriteGEPAsOffset(), and llvm::InstCombinerImpl::visitFAdd().

◆ CreateNSWMul()

Value * llvm::IRBuilderBase::CreateNSWMul ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1364 of file IRBuilder.h.

References CreateMul(), LHS, Name, and RHS.

Referenced by llvm::InstCombinerImpl::visitCallInst(), and llvm::InstCombinerImpl::visitMul().

◆ CreateNSWNeg()

Value * llvm::IRBuilderBase::CreateNSWNeg ( Value V,
const Twine Name = "" 
)
inline

Definition at line 1721 of file IRBuilder.h.

References CreateNeg(), and Name.

◆ CreateNSWSub()

Value * llvm::IRBuilderBase::CreateNSWSub ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1347 of file IRBuilder.h.

References CreateSub(), LHS, Name, and RHS.

◆ CreateNUWAdd()

Value * llvm::IRBuilderBase::CreateNUWAdd ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1334 of file IRBuilder.h.

References CreateAdd(), LHS, Name, and RHS.

Referenced by foldNoWrapAdd().

◆ CreateNUWMul()

Value * llvm::IRBuilderBase::CreateNUWMul ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1368 of file IRBuilder.h.

References CreateMul(), LHS, Name, and RHS.

Referenced by buildUMulWithOverflowFunc().

◆ CreateNUWNeg()

Value * llvm::IRBuilderBase::CreateNUWNeg ( Value V,
const Twine Name = "" 
)
inline

Definition at line 1725 of file IRBuilder.h.

References CreateNeg(), and Name.

◆ CreateNUWSub()

Value * llvm::IRBuilderBase::CreateNUWSub ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1351 of file IRBuilder.h.

References CreateSub(), LHS, Name, and RHS.

◆ CreateOr() [1/4]

Value * llvm::IRBuilderBase::CreateOr ( ArrayRef< Value * >  Ops)
inline

◆ CreateOr() [2/4]

Value * llvm::IRBuilderBase::CreateOr ( Value LHS,
const APInt RHS,
const Twine Name = "" 
)
inline

Definition at line 1497 of file IRBuilder.h.

References CreateOr(), LHS, Name, and RHS.

◆ CreateOr() [3/4]

Value * llvm::IRBuilderBase::CreateOr ( Value LHS,
uint64_t  RHS,
const Twine Name = "" 
)
inline

Definition at line 1501 of file IRBuilder.h.

References CreateOr(), LHS, Name, and RHS.

◆ CreateOr() [4/4]

Value * llvm::IRBuilderBase::CreateOr ( Value LHS,
Value RHS,
const Twine Name = "" 
)
inline

Definition at line 1491 of file IRBuilder.h.

References llvm::IRBuilderFolder::FoldBinOp(), Folder, Insert(), LHS, Name, and RHS.

Referenced by llvm::addDiffRuntimeChecks(), llvm::addRuntimeChecks(), llvm::buildAtomicRMWValue(), buildPartialUnswitchConditionalBranch(), checkForNegativeOperand(), createLogicFromTable(), CreateOr(), llvm::OpenMPIRBuilder::createTask(), llvm::emitAMDGPUPrintfCall(), llvm::AArch64TargetLowering::emitLoadLinked(), llvm::ARMTargetLowering::emitLoadLinked(), llvm::PPCTargetLowering::emitMaskedAtomicCmpXchgIntrinsic(), llvm::PPCTargetLowering::emitMaskedAtomicRMWIntrinsic(), expandFPToI(), expandIToFP(), llvm::SCEVExpander::expandUnionPredicate(), llvm::SCEVExpander::expandWrapPredicate(), foldComplexAndOrPatterns(), llvm::InstCombinerImpl::foldICmpAndConstConst(), llvm::InstCombinerImpl::foldICmpEqIntrinsicWithConstant(), foldICmpOrXX(), llvm::InstCombinerImpl::foldICmpSelectConstant(), llvm::InstCombinerImpl::foldICmpSubConstant(), llvm::InstCombinerImpl::foldICmpWithZextOrSext(), foldLogOpOfMaskedICmps(), foldSelectICmpAnd(), foldSelectICmpAndAnd(), foldSwitchToSelect(), llvm::SCEVExpander::generateOverflowCheck(), generateUnsignedDivisionCode(), getBoundsCheckCond(), llvm::VNCoercion::getMemInstValueForLoad(), insertMaskedValue(), LowerBSWAP(), LowerCTLZ(), lowerFunnelShifts(), matchOrConcat(), mergeConditionalStoreToAddress(), performMaskedAtomicOp(), llvm::InstCombinerImpl::SimplifyDemandedUseBits(), simplifyTernarylogic(), llvm::UpgradeIntrinsicCall(), llvm::LoopVersioning::versionLoop(), llvm::InstCombinerImpl::visitOr(), llvm::InstCombinerImpl::visitTrunc(), and llvm::InstCombinerImpl::visitXor().

◆ CreateOrReduce()

CallInst * IRBuilderBase::CreateOrReduce ( Value Src)

Create a vector int OR reduction intrinsic of the source vector.

Definition at line 445 of file IRBuilder.cpp.

Referenced by llvm::createAnyOfTargetReduction(), llvm::createSimpleTargetReduction(), and llvm::InstCombinerImpl::visitCallInst().

◆ CreatePHI()

PHINode * llvm::IRBuilderBase::CreatePHI ( Type Ty,
unsigned  NumReservedValues,
const Twine Name = "" 
)
inline

◆ CreatePointerBitCastOrAddrSpaceCast()

Value * llvm::IRBuilderBase::CreatePointerBitCastOrAddrSpaceCast ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreatePointerCast()

Value * llvm::IRBuilderBase::CreatePointerCast ( Value V,
Type DestTy,
const Twine Name = "" 
)
inline

◆ CreatePreserveArrayAccessIndex()

Value * IRBuilderBase::CreatePreserveArrayAccessIndex ( Type ElTy,
Value Base,
unsigned  Dimension,
unsigned  LastIndex,
MDNode DbgInfo 
)

◆ CreatePreserveStructAccessIndex()

Value * IRBuilderBase::CreatePreserveStructAccessIndex ( Type ElTy,
Value Base,
unsigned  Index,
unsigned  FieldIndex,
MDNode DbgInfo 
)