|
LLVM 23.0.0git
|
Common base class shared among various IRBuilders. More...
#include "llvm/IR/IRBuilder.h"
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. | |
| Constant * | Insert (Constant *C, const Twine &="") const |
| No-op overload to handle constants. | |
| Value * | Insert (Value *V, const Twine &Name="") const |
| void | ClearInsertionPoint () |
| Clear the insertion point: created instructions will not be inserted into a block. | |
| BasicBlock * | GetInsertBlock () const |
| BasicBlock::iterator | GetInsertPoint () const |
| LLVMContext & | getContext () 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 | SetNoSanitizeMetadata () |
| Set nosanitize metadata. | |
| void | CollectMetadataToCopy (Instruction *Src, ArrayRef< unsigned > MetadataKinds) |
Collect metadata with IDs MetadataKinds from Src which should be added to all created instructions. | |
| LLVM_ABI DebugLoc | getCurrentDebugLocation () const |
| Get location information used by debugging information. | |
| LLVM_ABI 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. | |
| LLVM_ABI Type * | getCurrentFunctionReturnType () 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. | |
| MDNode * | getDefaultFPMathTag () const |
| Get the floating point math metadata being used. | |
| FastMathFlags | getFastMathFlags () const |
| Get the flags to be applied to created floating point ops. | |
| FastMathFlags & | getFastMathFlags () |
| 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) |
| LLVM_ABI GlobalVariable * | CreateGlobalString (StringRef Str, const Twine &Name="", unsigned AddressSpace=0, Module *M=nullptr, bool AddNull=true) |
| Make a new global variable with initializer type i8*. | |
| ConstantInt * | getInt1 (bool V) |
| Get a constant value representing either true or false. | |
| ConstantInt * | getTrue () |
| Get the constant value for i1 true. | |
| ConstantInt * | getFalse () |
| Get the constant value for i1 false. | |
| ConstantInt * | getInt8 (uint8_t C) |
| Get a constant 8-bit value. | |
| ConstantInt * | getInt16 (uint16_t C) |
| Get a constant 16-bit value. | |
| ConstantInt * | getInt32 (uint32_t C) |
| Get a constant 32-bit value. | |
| ConstantInt * | getInt64 (uint64_t C) |
| Get a constant 64-bit value. | |
| ConstantInt * | getIntN (unsigned N, uint64_t C) |
| Get a constant N-bit value, zero extended from a 64-bit value. | |
| ConstantInt * | getInt (const APInt &AI) |
| Get a constant integer value. | |
| IntegerType * | getInt1Ty () |
| Fetch the type representing a single bit. | |
| IntegerType * | getInt8Ty () |
| Fetch the type representing an 8-bit integer. | |
| IntegerType * | getInt16Ty () |
| Fetch the type representing a 16-bit integer. | |
| IntegerType * | getInt32Ty () |
| Fetch the type representing a 32-bit integer. | |
| IntegerType * | getInt64Ty () |
| Fetch the type representing a 64-bit integer. | |
| IntegerType * | getInt128Ty () |
| Fetch the type representing a 128-bit integer. | |
| IntegerType * | getIntNTy (unsigned N) |
| Fetch the type representing an N-bit integer. | |
| Type * | getHalfTy () |
| Fetch the type representing a 16-bit floating point value. | |
| Type * | getBFloatTy () |
| Fetch the type representing a 16-bit brain floating point value. | |
| Type * | getFloatTy () |
| Fetch the type representing a 32-bit floating point value. | |
| Type * | getDoubleTy () |
| Fetch the type representing a 64-bit floating point value. | |
| Type * | getVoidTy () |
| Fetch the type representing void. | |
| PointerType * | getPtrTy (unsigned AddrSpace=0) |
| Fetch the type representing a pointer. | |
| IntegerType * | getIntPtrTy (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. | |
| IntegerType * | getIndexTy (const DataLayout &DL, unsigned AddrSpace) |
| Fetch the type of an integer that should be used to index GEP operations within AddressSpace. | |
| CallInst * | CreateMemSet (Value *Ptr, Value *Val, uint64_t Size, MaybeAlign Align, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| Create and insert a memset to the specified pointer and the specified value. | |
| LLVM_ABI CallInst * | CreateMemSet (Value *Ptr, Value *Val, Value *Size, MaybeAlign Align, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| LLVM_ABI CallInst * | CreateMemSetInline (Value *Dst, MaybeAlign DstAlign, Value *Val, Value *Size, bool IsVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| CallInst * | CreateElementUnorderedAtomicMemSet (Value *Ptr, Value *Val, uint64_t Size, Align Alignment, uint32_t ElementSize, const AAMDNodes &AAInfo=AAMDNodes()) |
| Create and insert an element unordered-atomic memset of the region of memory starting at the given pointer to the given value. | |
| LLVM_ABI CallInst * | CreateMalloc (Type *IntPtrTy, Type *AllocTy, Value *AllocSize, Value *ArraySize, ArrayRef< OperandBundleDef > OpB, Function *MallocF=nullptr, const Twine &Name="") |
| LLVM_ABI CallInst * | CreateMalloc (Type *IntPtrTy, Type *AllocTy, Value *AllocSize, Value *ArraySize, Function *MallocF=nullptr, const Twine &Name="") |
| CreateMalloc - Generate the IR for a call to malloc: | |
| LLVM_ABI CallInst * | CreateFree (Value *Source, ArrayRef< OperandBundleDef > Bundles={}) |
| Generate the IR for a call to the builtin free function. | |
| LLVM_ABI CallInst * | CreateElementUnorderedAtomicMemSet (Value *Ptr, Value *Val, Value *Size, Align Alignment, uint32_t ElementSize, const AAMDNodes &AAInfo=AAMDNodes()) |
| CallInst * | CreateMemCpy (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, uint64_t Size, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| Create and insert a memcpy between the specified pointers. | |
| LLVM_ABI CallInst * | CreateMemTransferInst (Intrinsic::ID IntrID, Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| CallInst * | CreateMemCpy (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| CallInst * | CreateMemCpyInline (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| LLVM_ABI CallInst * | CreateElementUnorderedAtomicMemCpy (Value *Dst, Align DstAlign, Value *Src, Align SrcAlign, Value *Size, uint32_t ElementSize, const AAMDNodes &AAInfo=AAMDNodes()) |
| Create and insert an element unordered-atomic memcpy between the specified pointers. | |
| CallInst * | CreateMemMove (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, uint64_t Size, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| CallInst * | CreateMemMove (Value *Dst, MaybeAlign DstAlign, Value *Src, MaybeAlign SrcAlign, Value *Size, bool isVolatile=false, const AAMDNodes &AAInfo=AAMDNodes()) |
| LLVM_ABI CallInst * | CreateElementUnorderedAtomicMemMove (Value *Dst, Align DstAlign, Value *Src, Align SrcAlign, Value *Size, uint32_t ElementSize, const AAMDNodes &AAInfo=AAMDNodes()) |
| Create and insert an element unordered-atomic memmove between the specified pointers. | |
| LLVM_ABI CallInst * | CreateFAddReduce (Value *Acc, Value *Src) |
| Create a sequential vector fadd reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateFMulReduce (Value *Acc, Value *Src) |
| Create a sequential vector fmul reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateAddReduce (Value *Src) |
| Create a vector int add reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateMulReduce (Value *Src) |
| Create a vector int mul reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateAndReduce (Value *Src) |
| Create a vector int AND reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateOrReduce (Value *Src) |
| Create a vector int OR reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateXorReduce (Value *Src) |
| Create a vector int XOR reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateIntMaxReduce (Value *Src, bool IsSigned=false) |
| Create a vector integer max reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateIntMinReduce (Value *Src, bool IsSigned=false) |
| Create a vector integer min reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateFPMaxReduce (Value *Src) |
| Create a vector float max reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateFPMinReduce (Value *Src) |
| Create a vector float min reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateFPMaximumReduce (Value *Src) |
| Create a vector float maximum reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateFPMinimumReduce (Value *Src) |
| Create a vector float minimum reduction intrinsic of the source vector. | |
| LLVM_ABI CallInst * | CreateLifetimeStart (Value *Ptr) |
| Create a lifetime.start intrinsic. | |
| LLVM_ABI CallInst * | CreateLifetimeEnd (Value *Ptr) |
| Create a lifetime.end intrinsic. | |
| LLVM_ABI CallInst * | CreateInvariantStart (Value *Ptr, ConstantInt *Size=nullptr) |
| Create a call to invariant.start intrinsic. | |
| LLVM_ABI CallInst * | CreateThreadLocalAddress (Value *Ptr) |
| Create a call to llvm.threadlocal.address intrinsic. | |
| LLVM_ABI CallInst * | CreateMaskedLoad (Type *Ty, Value *Ptr, Align Alignment, Value *Mask, Value *PassThru=nullptr, const Twine &Name="") |
| Create a call to Masked Load intrinsic. | |
| LLVM_ABI CallInst * | CreateMaskedStore (Value *Val, Value *Ptr, Align Alignment, Value *Mask) |
| Create a call to Masked Store intrinsic. | |
| LLVM_ABI CallInst * | CreateMaskedGather (Type *Ty, Value *Ptrs, Align Alignment, Value *Mask=nullptr, Value *PassThru=nullptr, const Twine &Name="") |
| Create a call to Masked Gather intrinsic. | |
| LLVM_ABI CallInst * | CreateMaskedScatter (Value *Val, Value *Ptrs, Align Alignment, Value *Mask=nullptr) |
| Create a call to Masked Scatter intrinsic. | |
| LLVM_ABI CallInst * | CreateMaskedExpandLoad (Type *Ty, Value *Ptr, MaybeAlign Align, Value *Mask=nullptr, Value *PassThru=nullptr, const Twine &Name="") |
| Create a call to Masked Expand Load intrinsic. | |
| LLVM_ABI CallInst * | CreateMaskedCompressStore (Value *Val, Value *Ptr, MaybeAlign Align, Value *Mask=nullptr) |
| Create a call to Masked Compress Store intrinsic. | |
| Value * | getAllOnesMask (ElementCount NumElts) |
Return an all true boolean vector (mask) with NumElts lanes. | |
| LLVM_ABI CallInst * | CreateAssumption (Value *Cond, ArrayRef< OperandBundleDef > OpBundles={}) |
| Create an assume intrinsic call that allows the optimizer to assume that the provided condition will be true. | |
| LLVM_ABI Instruction * | CreateNoAliasScopeDeclaration (Value *Scope) |
| Create a llvm.experimental.noalias.scope.decl intrinsic call. | |
| Instruction * | CreateNoAliasScopeDeclaration (MDNode *ScopeTag) |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI InvokeInst * | 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. | |
| LLVM_ABI InvokeInst * | 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. | |
| LLVM_ABI InvokeInst * | 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="") |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | 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. | |
| Value * | CreateVScale (Type *Ty, const Twine &Name="") |
| Create a call to llvm.vscale.<Ty>(). | |
| LLVM_ABI Value * | CreateElementCount (Type *Ty, ElementCount EC) |
Create an expression which evaluates to the number of elements in EC at runtime. | |
| LLVM_ABI Value * | CreateTypeSize (Type *Ty, TypeSize Size) |
Create an expression which evaluates to the number of units in Size at runtime. | |
| LLVM_ABI Value * | CreateAllocationSize (Type *DestTy, AllocaInst *AI) |
| Get allocation size of an alloca as a runtime Value* (handles both static and dynamic allocas and vscale factor). | |
| LLVM_ABI Value * | CreateStepVector (Type *DstType, const Twine &Name="") |
Creates a vector of type DstType with the linear sequence <0, 1, ...> | |
| LLVM_ABI CallInst * | CreateUnaryIntrinsic (Intrinsic::ID ID, Value *V, FMFSource FMFSource={}, const Twine &Name="") |
Create a call to intrinsic ID with 1 operand which is mangled on its type. | |
| LLVM_ABI Value * | CreateBinaryIntrinsic (Intrinsic::ID ID, Value *LHS, Value *RHS, FMFSource FMFSource={}, const Twine &Name="") |
Create a call to intrinsic ID with 2 operands which is mangled on the first type. | |
| LLVM_ABI CallInst * | CreateIntrinsic (Intrinsic::ID ID, ArrayRef< Type * > Types, ArrayRef< Value * > Args, FMFSource FMFSource={}, const Twine &Name="") |
Create a call to intrinsic ID with Args, mangled using Types. | |
| LLVM_ABI CallInst * | CreateIntrinsic (Type *RetTy, Intrinsic::ID ID, ArrayRef< Value * > Args, FMFSource FMFSource={}, const Twine &Name="") |
Create a call to intrinsic ID with RetTy and Args. | |
| CallInst * | CreateIntrinsic (Intrinsic::ID ID, ArrayRef< Value * > Args, FMFSource FMFSource={}, const Twine &Name="") |
Create a call to non-overloaded intrinsic ID with Args. | |
| Value * | CreateMinNum (Value *LHS, Value *RHS, FMFSource FMFSource={}, const Twine &Name="") |
| Create call to the minnum intrinsic. | |
| Value * | CreateMaxNum (Value *LHS, Value *RHS, FMFSource FMFSource={}, const Twine &Name="") |
| Create call to the maxnum intrinsic. | |
| Value * | CreateMinimum (Value *LHS, Value *RHS, const Twine &Name="") |
| Create call to the minimum intrinsic. | |
| Value * | CreateMaximum (Value *LHS, Value *RHS, const Twine &Name="") |
| Create call to the maximum intrinsic. | |
| Value * | CreateMinimumNum (Value *LHS, Value *RHS, const Twine &Name="") |
| Create call to the minimumnum intrinsic. | |
| Value * | CreateMaximumNum (Value *LHS, Value *RHS, const Twine &Name="") |
| Create call to the maximum intrinsic. | |
| Value * | CreateCopySign (Value *LHS, Value *RHS, FMFSource FMFSource={}, const Twine &Name="") |
| Create call to the copysign intrinsic. | |
| Value * | CreateLdexp (Value *Src, Value *Exp, FMFSource FMFSource={}, const Twine &Name="") |
| Create call to the ldexp intrinsic. | |
| Value * | CreateFMA (Value *Factor1, Value *Factor2, Value *Summand, FMFSource FMFSource={}, const Twine &Name="") |
| Create call to the fma intrinsic. | |
| CallInst * | CreateArithmeticFence (Value *Val, Type *DstType, const Twine &Name="") |
| Create a call to the arithmetic_fence intrinsic. | |
| CallInst * | CreateExtractVector (Type *DstType, Value *SrcVec, Value *Idx, const Twine &Name="") |
| Create a call to the vector.extract intrinsic. | |
| CallInst * | CreateExtractVector (Type *DstType, Value *SrcVec, uint64_t Idx, const Twine &Name="") |
| Create a call to the vector.extract intrinsic. | |
| CallInst * | CreateInsertVector (Type *DstType, Value *SrcVec, Value *SubVec, Value *Idx, const Twine &Name="") |
| Create a call to the vector.insert intrinsic. | |
| CallInst * | CreateInsertVector (Type *DstType, Value *SrcVec, Value *SubVec, uint64_t Idx, const Twine &Name="") |
| Create a call to the vector.extract intrinsic. | |
| CallInst * | CreateStackSave (const Twine &Name="") |
| Create a call to llvm.stacksave. | |
| CallInst * | CreateStackRestore (Value *Ptr, const Twine &Name="") |
| Create a call to llvm.stackrestore. | |
| Value * | CreateCountTrailingZeroElems (Type *ResTy, Value *Mask, bool ZeroIsPoison=true, const Twine &Name="") |
| Create a call to llvm.experimental_cttz_elts. | |
| ReturnInst * | CreateRetVoid () |
| Create a 'ret void' instruction. | |
| ReturnInst * | CreateRet (Value *V) |
| Create a 'ret <val>' instruction. | |
| ReturnInst * | CreateAggregateRet (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. | |
| BranchInst * | CreateBr (BasicBlock *Dest) |
| Create an unconditional 'br label X' instruction. | |
| BranchInst * | CreateCondBr (Value *Cond, BasicBlock *True, BasicBlock *False, MDNode *BranchWeights=nullptr, MDNode *Unpredictable=nullptr) |
| Create a conditional 'br Cond, TrueDest, FalseDest' instruction. | |
| BranchInst * | CreateCondBr (Value *Cond, BasicBlock *True, BasicBlock *False, Instruction *MDSrc) |
| Create a conditional 'br Cond, TrueDest, FalseDest' instruction. | |
| SwitchInst * | CreateSwitch (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). | |
| IndirectBrInst * | CreateIndirectBr (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). | |
| InvokeInst * | CreateInvoke (FunctionType *Ty, Value *Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="") |
| Create an invoke instruction. | |
| InvokeInst * | CreateInvoke (FunctionType *Ty, Value *Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args={}, const Twine &Name="") |
| InvokeInst * | CreateInvoke (FunctionCallee Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="") |
| InvokeInst * | CreateInvoke (FunctionCallee Callee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value * > Args={}, const Twine &Name="") |
| CallBrInst * | CreateCallBr (FunctionType *Ty, Value *Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args={}, const Twine &Name="") |
| Create a callbr instruction. | |
| CallBrInst * | CreateCallBr (FunctionType *Ty, Value *Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="") |
| CallBrInst * | CreateCallBr (FunctionCallee Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args={}, const Twine &Name="") |
| CallBrInst * | CreateCallBr (FunctionCallee Callee, BasicBlock *DefaultDest, ArrayRef< BasicBlock * > IndirectDests, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="") |
| ResumeInst * | CreateResume (Value *Exn) |
| CleanupReturnInst * | CreateCleanupRet (CleanupPadInst *CleanupPad, BasicBlock *UnwindBB=nullptr) |
| CatchSwitchInst * | CreateCatchSwitch (Value *ParentPad, BasicBlock *UnwindBB, unsigned NumHandlers, const Twine &Name="") |
| CatchPadInst * | CreateCatchPad (Value *ParentPad, ArrayRef< Value * > Args, const Twine &Name="") |
| CleanupPadInst * | CreateCleanupPad (Value *ParentPad, ArrayRef< Value * > Args={}, const Twine &Name="") |
| CatchReturnInst * | CreateCatchRet (CatchPadInst *CatchPad, BasicBlock *BB) |
| UnreachableInst * | CreateUnreachable () |
| Value * | CreateAdd (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false) |
| Value * | CreateNSWAdd (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateNUWAdd (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateSub (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false) |
| Value * | CreateNSWSub (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateNUWSub (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateMul (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false) |
| Value * | CreateNSWMul (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateNUWMul (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateUDiv (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateExactUDiv (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateSDiv (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateExactSDiv (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateURem (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateSRem (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateShl (Value *LHS, Value *RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false) |
| Value * | CreateShl (Value *LHS, const APInt &RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false) |
| Value * | CreateShl (Value *LHS, uint64_t RHS, const Twine &Name="", bool HasNUW=false, bool HasNSW=false) |
| Value * | CreateLShr (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateLShr (Value *LHS, const APInt &RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateLShr (Value *LHS, uint64_t RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateAShr (Value *LHS, Value *RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateAShr (Value *LHS, const APInt &RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateAShr (Value *LHS, uint64_t RHS, const Twine &Name="", bool isExact=false) |
| Value * | CreateAnd (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateAnd (Value *LHS, const APInt &RHS, const Twine &Name="") |
| Value * | CreateAnd (Value *LHS, uint64_t RHS, const Twine &Name="") |
| Value * | CreateAnd (ArrayRef< Value * > Ops) |
| Value * | CreateOr (Value *LHS, Value *RHS, const Twine &Name="", bool IsDisjoint=false) |
| Value * | CreateOr (Value *LHS, const APInt &RHS, const Twine &Name="") |
| Value * | CreateOr (Value *LHS, uint64_t RHS, const Twine &Name="") |
| Value * | CreateOr (ArrayRef< Value * > Ops) |
| Value * | CreateXor (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateXor (Value *LHS, const APInt &RHS, const Twine &Name="") |
| Value * | CreateXor (Value *LHS, uint64_t RHS, const Twine &Name="") |
| Value * | CreateFAdd (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFAddFMF (Value *L, Value *R, FMFSource FMFSource, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFSub (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFSubFMF (Value *L, Value *R, FMFSource FMFSource, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFMul (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFMulFMF (Value *L, Value *R, FMFSource FMFSource, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFDiv (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFDivFMF (Value *L, Value *R, FMFSource FMFSource, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFRem (Value *L, Value *R, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateFRemFMF (Value *L, Value *R, FMFSource FMFSource, const Twine &Name="", MDNode *FPMD=nullptr) |
| Value * | CreateBinOp (Instruction::BinaryOps Opc, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateBinOpFMF (Instruction::BinaryOps Opc, Value *LHS, Value *RHS, FMFSource FMFSource, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateLogicalAnd (Value *Cond1, Value *Cond2, const Twine &Name="", Instruction *MDFrom=nullptr) |
| Value * | CreateLogicalOr (Value *Cond1, Value *Cond2, const Twine &Name="", Instruction *MDFrom=nullptr) |
| Value * | CreateLogicalOp (Instruction::BinaryOps Opc, Value *Cond1, Value *Cond2, const Twine &Name="", Instruction *MDFrom=nullptr) |
| Value * | CreateLogicalOr (ArrayRef< Value * > Ops) |
| LLVM_ABI CallInst * | CreateConstrainedFPIntrinsic (Intrinsic::ID ID, ArrayRef< Type * > Types, ArrayRef< Value * > Args, FMFSource FMFSource, const Twine &Name, MDNode *FPMathTag=nullptr, std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt) |
| This function is like CreateIntrinsic for constrained fp intrinsics. | |
| LLVM_ABI CallInst * | CreateConstrainedFPBinOp (Intrinsic::ID ID, Value *L, Value *R, FMFSource FMFSource={}, const Twine &Name="", MDNode *FPMathTag=nullptr, std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt) |
| LLVM_ABI CallInst * | CreateConstrainedFPUnroundedBinOp (Intrinsic::ID ID, Value *L, Value *R, FMFSource FMFSource={}, const Twine &Name="", MDNode *FPMathTag=nullptr, std::optional< fp::ExceptionBehavior > Except=std::nullopt) |
| Value * | CreateNeg (Value *V, const Twine &Name="", bool HasNSW=false) |
| Value * | CreateNSWNeg (Value *V, const Twine &Name="") |
| Value * | CreateFNeg (Value *V, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFNegFMF (Value *V, FMFSource FMFSource, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateNot (Value *V, const Twine &Name="") |
| Value * | CreateUnOp (Instruction::UnaryOps Opc, Value *V, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| LLVM_ABI Value * | CreateNAryOp (unsigned Opc, ArrayRef< Value * > Ops, const Twine &Name="", MDNode *FPMathTag=nullptr) |
Create either a UnaryOperator or BinaryOperator depending on Opc. | |
| AllocaInst * | CreateAlloca (Type *Ty, unsigned AddrSpace, Value *ArraySize=nullptr, const Twine &Name="") |
| AllocaInst * | CreateAlloca (Type *Ty, Value *ArraySize=nullptr, const Twine &Name="") |
| LoadInst * | CreateLoad (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. | |
| LoadInst * | CreateLoad (Type *Ty, Value *Ptr, const Twine &Name="") |
| LoadInst * | CreateLoad (Type *Ty, Value *Ptr, bool isVolatile, const Twine &Name="") |
| StoreInst * | CreateStore (Value *Val, Value *Ptr, bool isVolatile=false) |
| LoadInst * | CreateAlignedLoad (Type *Ty, Value *Ptr, MaybeAlign Align, const char *Name) |
| LoadInst * | CreateAlignedLoad (Type *Ty, Value *Ptr, MaybeAlign Align, const Twine &Name="") |
| LoadInst * | CreateAlignedLoad (Type *Ty, Value *Ptr, MaybeAlign Align, bool isVolatile, const Twine &Name="") |
| StoreInst * | CreateAlignedStore (Value *Val, Value *Ptr, MaybeAlign Align, bool isVolatile=false) |
| FenceInst * | CreateFence (AtomicOrdering Ordering, SyncScope::ID SSID=SyncScope::System, const Twine &Name="") |
| AtomicCmpXchgInst * | CreateAtomicCmpXchg (Value *Ptr, Value *Cmp, Value *New, MaybeAlign Align, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SyncScope::ID SSID=SyncScope::System) |
| AtomicRMWInst * | CreateAtomicRMW (AtomicRMWInst::BinOp Op, Value *Ptr, Value *Val, MaybeAlign Align, AtomicOrdering Ordering, SyncScope::ID SSID=SyncScope::System) |
| CallInst * | CreateStructuredGEP (Type *BaseType, Value *PtrBase, ArrayRef< Value * > Indices, const Twine &Name="") |
| Value * | CreateGEP (Type *Ty, Value *Ptr, ArrayRef< Value * > IdxList, const Twine &Name="", GEPNoWrapFlags NW=GEPNoWrapFlags::none()) |
| Value * | CreateInBoundsGEP (Type *Ty, Value *Ptr, ArrayRef< Value * > IdxList, const Twine &Name="") |
| Value * | CreateConstGEP1_32 (Type *Ty, Value *Ptr, unsigned Idx0, const Twine &Name="") |
| Value * | CreateConstInBoundsGEP1_32 (Type *Ty, Value *Ptr, unsigned Idx0, const Twine &Name="") |
| Value * | CreateConstGEP2_32 (Type *Ty, Value *Ptr, unsigned Idx0, unsigned Idx1, const Twine &Name="", GEPNoWrapFlags NWFlags=GEPNoWrapFlags::none()) |
| Value * | CreateConstInBoundsGEP2_32 (Type *Ty, Value *Ptr, unsigned Idx0, unsigned Idx1, const Twine &Name="") |
| Value * | CreateConstGEP1_64 (Type *Ty, Value *Ptr, uint64_t Idx0, const Twine &Name="") |
| Value * | CreateConstInBoundsGEP1_64 (Type *Ty, Value *Ptr, uint64_t Idx0, const Twine &Name="") |
| Value * | CreateConstGEP2_64 (Type *Ty, Value *Ptr, uint64_t Idx0, uint64_t Idx1, const Twine &Name="") |
| Value * | CreateConstInBoundsGEP2_64 (Type *Ty, Value *Ptr, uint64_t Idx0, uint64_t Idx1, const Twine &Name="") |
| Value * | CreateStructGEP (Type *Ty, Value *Ptr, unsigned Idx, const Twine &Name="") |
| Value * | CreatePtrAdd (Value *Ptr, Value *Offset, const Twine &Name="", GEPNoWrapFlags NW=GEPNoWrapFlags::none()) |
| Value * | CreateInBoundsPtrAdd (Value *Ptr, Value *Offset, const Twine &Name="") |
| Value * | CreateTrunc (Value *V, Type *DestTy, const Twine &Name="", bool IsNUW=false, bool IsNSW=false) |
| Value * | CreateZExt (Value *V, Type *DestTy, const Twine &Name="", bool IsNonNeg=false) |
| Value * | CreateSExt (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateZExtOrTrunc (Value *V, Type *DestTy, const Twine &Name="") |
| Create a ZExt or Trunc from the integer value V to DestTy. | |
| Value * | CreateSExtOrTrunc (Value *V, Type *DestTy, const Twine &Name="") |
| Create a SExt or Trunc from the integer value V to DestTy. | |
| Value * | CreateFPToUI (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateFPToSI (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateUIToFP (Value *V, Type *DestTy, const Twine &Name="", bool IsNonNeg=false) |
| Value * | CreateSIToFP (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateFPTrunc (Value *V, Type *DestTy, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFPTruncFMF (Value *V, Type *DestTy, FMFSource FMFSource, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFPExt (Value *V, Type *DestTy, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFPExtFMF (Value *V, Type *DestTy, FMFSource FMFSource, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreatePtrToAddr (Value *V, const Twine &Name="") |
| Value * | CreatePtrToInt (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateIntToPtr (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateBitCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateAddrSpaceCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateZExtOrBitCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateSExtOrBitCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateTruncOrBitCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateCast (Instruction::CastOps Op, Value *V, Type *DestTy, const Twine &Name="", MDNode *FPMathTag=nullptr, FMFSource FMFSource={}) |
| Value * | CreatePointerCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreatePointerBitCastOrAddrSpaceCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateIntCast (Value *V, Type *DestTy, bool isSigned, const Twine &Name="") |
| Value * | CreateBitOrPointerCast (Value *V, Type *DestTy, const Twine &Name="") |
| Value * | CreateFPCast (Value *V, Type *DestTy, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| LLVM_ABI CallInst * | CreateConstrainedFPCast (Intrinsic::ID ID, Value *V, Type *DestTy, FMFSource FMFSource={}, const Twine &Name="", MDNode *FPMathTag=nullptr, std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt) |
| Value * | CreateIntCast (Value *, Type *, const char *)=delete |
| LLVM_ABI Value * | CreateAggregateCast (Value *V, Type *DestTy) |
| Cast between aggregate types that must have identical structure but may differ in their leaf types. | |
| Value * | CreateICmpEQ (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpNE (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpUGT (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpUGE (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpULT (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpULE (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpSGT (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpSGE (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpSLT (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateICmpSLE (Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateFCmpOEQ (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpOGT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpOGE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpOLT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpOLE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpONE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpORD (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpUNO (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpUEQ (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpUGT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpUGE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpULT (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpULE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpUNE (Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateICmp (CmpInst::Predicate P, Value *LHS, Value *RHS, const Twine &Name="") |
| Value * | CreateFCmp (CmpInst::Predicate P, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpFMF (CmpInst::Predicate P, Value *LHS, Value *RHS, FMFSource FMFSource, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateCmp (CmpInst::Predicate Pred, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| Value * | CreateFCmpS (CmpInst::Predicate P, Value *LHS, Value *RHS, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| LLVM_ABI CallInst * | CreateConstrainedFPCmp (Intrinsic::ID ID, CmpInst::Predicate P, Value *L, Value *R, const Twine &Name="", std::optional< fp::ExceptionBehavior > Except=std::nullopt) |
| PHINode * | CreatePHI (Type *Ty, unsigned NumReservedValues, const Twine &Name="") |
| CallInst * | CreateCall (FunctionType *FTy, Value *Callee, ArrayRef< Value * > Args={}, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| CallInst * | CreateCall (FunctionType *FTy, Value *Callee, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| CallInst * | CreateCall (FunctionCallee Callee, ArrayRef< Value * > Args={}, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| CallInst * | CreateCall (FunctionCallee Callee, ArrayRef< Value * > Args, ArrayRef< OperandBundleDef > OpBundles, const Twine &Name="", MDNode *FPMathTag=nullptr) |
| LLVM_ABI CallInst * | CreateConstrainedFPCall (Function *Callee, ArrayRef< Value * > Args, const Twine &Name="", std::optional< RoundingMode > Rounding=std::nullopt, std::optional< fp::ExceptionBehavior > Except=std::nullopt) |
| LLVM_ABI Value * | CreateSelectWithUnknownProfile (Value *C, Value *True, Value *False, StringRef PassName, const Twine &Name="") |
| LLVM_ABI Value * | CreateSelectFMFWithUnknownProfile (Value *C, Value *True, Value *False, FMFSource FMFSource, StringRef PassName, const Twine &Name="") |
| LLVM_ABI Value * | CreateSelect (Value *C, Value *True, Value *False, const Twine &Name="", Instruction *MDFrom=nullptr) |
| LLVM_ABI Value * | CreateSelectFMF (Value *C, Value *True, Value *False, FMFSource FMFSource, const Twine &Name="", Instruction *MDFrom=nullptr) |
| VAArgInst * | CreateVAArg (Value *List, Type *Ty, const Twine &Name="") |
| Value * | CreateExtractElement (Value *Vec, Value *Idx, const Twine &Name="") |
| Value * | CreateExtractElement (Value *Vec, uint64_t Idx, const Twine &Name="") |
| Value * | CreateInsertElement (Type *VecTy, Value *NewElt, Value *Idx, const Twine &Name="") |
| Value * | CreateInsertElement (Type *VecTy, Value *NewElt, uint64_t Idx, const Twine &Name="") |
| Value * | CreateInsertElement (Value *Vec, Value *NewElt, Value *Idx, const Twine &Name="") |
| Value * | CreateInsertElement (Value *Vec, Value *NewElt, uint64_t Idx, const Twine &Name="") |
| Value * | CreateShuffleVector (Value *V1, Value *V2, Value *Mask, const Twine &Name="") |
| Value * | CreateShuffleVector (Value *V1, Value *V2, ArrayRef< int > Mask, const Twine &Name="") |
| See class ShuffleVectorInst for a description of the mask representation. | |
| Value * | CreateShuffleVector (Value *V, ArrayRef< int > Mask, const Twine &Name="") |
| Create a unary shuffle. | |
| LLVM_ABI Value * | CreateVectorInterleave (ArrayRef< Value * > Ops, const Twine &Name="") |
| Value * | CreateExtractValue (Value *Agg, ArrayRef< unsigned > Idxs, const Twine &Name="") |
| Value * | CreateInsertValue (Value *Agg, Value *Val, ArrayRef< unsigned > Idxs, const Twine &Name="") |
| LandingPadInst * | CreateLandingPad (Type *Ty, unsigned NumClauses, const Twine &Name="") |
| Value * | CreateFreeze (Value *V, const Twine &Name="") |
| Value * | CreateIsNull (Value *Arg, const Twine &Name="") |
Return a boolean value testing if Arg == 0. | |
| Value * | CreateIsNotNull (Value *Arg, const Twine &Name="") |
Return a boolean value testing if Arg != 0. | |
| Value * | CreateIsNeg (Value *Arg, const Twine &Name="") |
Return a boolean value testing if Arg < 0. | |
| Value * | CreateIsNotNeg (Value *Arg, const Twine &Name="") |
Return a boolean value testing if Arg > -1. | |
| LLVM_ABI Value * | CreatePtrDiff (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. | |
| LLVM_ABI Value * | CreateLaunderInvariantGroup (Value *Ptr) |
| Create a launder.invariant.group intrinsic call. | |
| LLVM_ABI Value * | CreateStripInvariantGroup (Value *Ptr) |
| Create a strip.invariant.group intrinsic call. | |
| LLVM_ABI Value * | CreateVectorReverse (Value *V, const Twine &Name="") |
| Return a vector value that contains the vector V reversed. | |
| LLVM_ABI Value * | CreateVectorSpliceLeft (Value *V1, Value *V2, Value *Offset, const Twine &Name="") |
Create a vector.splice.left intrinsic call, or a shufflevector that produces the same result if the result type is a fixed-length vector and Offset is a constant. | |
| Value * | CreateVectorSpliceLeft (Value *V1, Value *V2, uint32_t Offset, const Twine &Name="") |
| LLVM_ABI Value * | CreateVectorSpliceRight (Value *V1, Value *V2, Value *Offset, const Twine &Name="") |
Create a vector.splice.right intrinsic call, or a shufflevector that produces the same result if the result type is a fixed-length vector and Offset is a constant. | |
| Value * | CreateVectorSpliceRight (Value *V1, Value *V2, uint32_t Offset, const Twine &Name="") |
| LLVM_ABI Value * | CreateVectorSplat (unsigned NumElts, Value *V, const Twine &Name="") |
| Return a vector value that contains. | |
| LLVM_ABI Value * | CreateVectorSplat (ElementCount EC, Value *V, const Twine &Name="") |
| Return a vector value that contains. | |
| LLVM_ABI Value * | CreatePreserveArrayAccessIndex (Type *ElTy, Value *Base, unsigned Dimension, unsigned LastIndex, MDNode *DbgInfo) |
| LLVM_ABI Value * | CreatePreserveUnionAccessIndex (Value *Base, unsigned FieldIndex, MDNode *DbgInfo) |
| LLVM_ABI Value * | CreatePreserveStructAccessIndex (Type *ElTy, Value *Base, unsigned Index, unsigned FieldIndex, MDNode *DbgInfo) |
| LLVM_ABI Value * | createIsFPClass (Value *FPNum, unsigned Test) |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | 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. | |
| LLVM_ABI CallInst * | CreateDereferenceableAssumption (Value *PtrValue, Value *SizeValue) |
| Create an assume intrinsic call that represents an dereferencable assumption on the provided pointer. | |
Common base class shared among various IRBuilders.
Definition at line 114 of file IRBuilder.h.
|
inline |
Definition at line 162 of file IRBuilder.h.
References ClearInsertionPoint(), Context, DefaultFPMathTag, DefaultOperandBundles, Folder, and Inserter.
Referenced by llvm::IRBuilderBase::FastMathFlagGuard::FastMathFlagGuard(), llvm::IRBuilderBase::InsertPointGuard::InsertPointGuard(), and llvm::IRBuilderBase::OperandBundlesGuard::OperandBundlesGuard().
|
inline |
Add all entries in MetadataToCopy to I.
Definition at line 280 of file IRBuilder.h.
References I, and SetInstDebugLocation().
Referenced by Insert().
|
inline |
|
inline |
Clear the insertion point: created instructions will not be inserted into a block.
Definition at line 196 of file IRBuilder.h.
Referenced by IRBuilderBase(), llvm::Negator::Negate(), restoreIP(), and saveAndClearIP().
|
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 262 of file IRBuilder.h.
References SetCurrentDebugLocation().
|
inline |
Definition at line 1406 of file IRBuilder.h.
References Folder, LHS, and RHS.
Referenced by convertToShadowDataInt(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), CreateNSWAdd(), CreateNUWAdd(), llvm::AMDGPU::createSlowPathCmp(), llvm::memtag::incrementThreadLong(), insertLoopExpansion(), llvm::AMDGPU::instrumentAddress(), llvm::lowerUnaryVectorIntrinsicAsLoop(), llvm::AMDGPU::memToShadow(), llvm::orc::ReOptimizeLayer::reoptimizeIfCallFrequent(), simplifyAMDGCNMemoryIntrinsicDemanded(), and llvm::UnrollRuntimeLoopRemainder().
Create a vector int add reduction intrinsic of the source vector.
Definition at line 378 of file IRBuilder.cpp.
|
inline |
Definition at line 2181 of file IRBuilder.h.
References CreateCast().
Referenced by convertToParamAS(), handleByValParam(), and simplifyInvariantGroupIntrinsic().
Cast between aggregate types that must have identical structure but may differ in their leaf types.
The leaf values are recursively extracted, casted, and then reinserted into a value of type DestTy. The leaf types must be castable using a bitcast or ptrcast, because signedness is not specified.
Definition at line 72 of file IRBuilder.cpp.
References llvm::ArrayRef(), assert(), CreateAggregateCast(), CreateBitOrPointerCast(), CreateExtractValue(), CreateInsertValue(), llvm::PoisonValue::get(), llvm::Type::getArrayElementType(), llvm::Type::getArrayNumElements(), llvm::Type::getStructElementType(), llvm::Type::getStructNumElements(), I, llvm::Type::isArrayTy(), and llvm::Type::isStructTy().
Referenced by CreateAggregateCast().
|
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 1186 of file IRBuilder.h.
References Context, llvm::ReturnInst::Create(), CreateInsertValue(), llvm::PoisonValue::get(), getCurrentFunctionReturnType(), Insert(), and N.
|
inline |
Definition at line 1881 of file IRBuilder.h.
|
inline |
Definition at line 1871 of file IRBuilder.h.
References CreateAlignedLoad().
Referenced by CreateAlignedLoad(), CreateAlignedLoad(), CreateLoad(), CreateLoad(), CreateLoad(), llvm::createMemCpyLoopKnownSize(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), doPromotion(), llvm::AMDGPU::instrumentAddressImpl(), llvm::lowerGlobalIFuncUsersAsGlobalCtor(), and unpackLoadToAggregate().
|
inline |
Definition at line 1876 of file IRBuilder.h.
References CreateAlignedLoad().
|
inline |
Definition at line 1890 of file IRBuilder.h.
References BB, DL, llvm::Value::getType(), and Insert().
Referenced by combineStoreToNewValue(), llvm::createMemCpyLoopKnownSize(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), CreateStore(), doPromotion(), llvm::lowerGlobalIFuncUsersAsGlobalCtor(), and unpackStoreToAggregate().
| 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 1287 of file IRBuilder.cpp.
References assert(), llvm::cast(), DL, getIntPtrTy(), llvm::Value::getType(), and llvm::isa().
| 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 1300 of file IRBuilder.cpp.
References assert(), DL, llvm::Value::getType(), and llvm::isa().
|
inline |
Definition at line 1837 of file IRBuilder.h.
References BB, DL, and Insert().
Referenced by doPromotion(), and simplifyAllocaArraySize().
|
inline |
Definition at line 1844 of file IRBuilder.h.
| Value * IRBuilderBase::CreateAllocationSize | ( | Type * | DestTy, |
| AllocaInst * | AI ) |
Get allocation size of an alloca as a runtime Value* (handles both static and dynamic allocas and vscale factor).
Definition at line 138 of file IRBuilder.cpp.
References BB, CreateMul(), CreateTypeSize(), CreateZExtOrTrunc(), DL, llvm::AllocaInst::getAllocatedType(), llvm::AllocaInst::getArraySize(), llvm::AllocaInst::isArrayAllocation(), and Size.
Definition at line 1568 of file IRBuilder.h.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), and CreateAnd().
|
inline |
Definition at line 1560 of file IRBuilder.h.
References CreateAnd(), LHS, and RHS.
|
inline |
Definition at line 1564 of file IRBuilder.h.
References CreateAnd(), LHS, and RHS.
Definition at line 1554 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by addBoundsChecking(), llvm::addRuntimeChecks(), buildPartialUnswitchConditionalBranch(), convertToShadowDataInt(), CreateAnd(), CreateAnd(), CreateAnd(), llvm::AMDGPU::createSlowPathCmp(), foldICmpAndXX(), foldICmpOrXX(), llvm::memtag::incrementThreadLong(), llvm::X86TTIImpl::instCombineIntrinsic(), and llvm::AMDGPU::instrumentAddressImpl().
Create a vector int AND reduction intrinsic of the source vector.
Definition at line 386 of file IRBuilder.cpp.
|
inline |
Create a call to the arithmetic_fence intrinsic.
Definition at line 1089 of file IRBuilder.h.
References CreateIntrinsic().
|
inline |
Definition at line 1544 of file IRBuilder.h.
References CreateAShr(), LHS, and RHS.
|
inline |
Definition at line 1549 of file IRBuilder.h.
References CreateAShr(), LHS, and RHS.
|
inline |
Definition at line 1535 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by CreateAShr(), CreateAShr(), llvm::memtag::incrementThreadLong(), and llvm::GCNTTIImpl::instCombineIntrinsic().
| CallInst * IRBuilderBase::CreateAssumption | ( | Value * | Cond, |
| ArrayRef< OperandBundleDef > | OpBundles = {} ) |
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 475 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), BB, Cond, CreateCall(), getInt1Ty(), and llvm::Intrinsic::getOrInsertDeclaration().
Referenced by ConnectEpilog(), and CreateDereferenceableAssumption().
|
inline |
Definition at line 1905 of file IRBuilder.h.
References BB, DL, Insert(), and llvm::SyncScope::System.
|
inline |
Definition at line 1918 of file IRBuilder.h.
References BB, DL, llvm::Value::getType(), Insert(), and llvm::SyncScope::System.
| Value * IRBuilderBase::CreateBinaryIntrinsic | ( | Intrinsic::ID | ID, |
| Value * | LHS, | ||
| Value * | RHS, | ||
| FMFSource | FMFSource = {}, | ||
| const Twine & | Name = "" ) |
Create a call to intrinsic ID with 2 operands which is mangled on the first type.
Definition at line 845 of file IRBuilder.cpp.
References BB, Folder, llvm::Intrinsic::getOrInsertDeclaration(), and llvm::Function::getReturnType().
Referenced by CreateMaximum(), CreateMaximumNum(), CreateMinimum(), CreateMinimumNum(), foldCttzCtlz(), and foldIdempotentBinaryIntrinsicRecurrence().
|
inline |
Definition at line 1711 of file IRBuilder.h.
References CreateBinOpFMF(), LHS, Opc, and RHS.
Referenced by CreateNAryOp(), foldLogicCastConstant(), matchDeMorgansLaws(), narrowUDivURem(), simplifyAndOrWithOpReplaced(), and llvm::X86TTIImpl::simplifyDemandedVectorEltsIntrinsic().
|
inline |
Definition at line 1717 of file IRBuilder.h.
References llvm::BinaryOperator::Create(), FMF, Folder, llvm::FMFSource::get(), Insert(), llvm::isa(), LHS, Opc, and RHS.
Referenced by CreateBinOp(), and instCombineSVEVectorBinOp().
|
inline |
Definition at line 2176 of file IRBuilder.h.
References CreateCast().
Referenced by canonicalizeBitCastExtElt(), llvm::VNCoercion::coerceAvailableValueToLoadType(), CreateBitOrPointerCast(), foldVecExtTruncToExtElt(), foldVecTruncToExtElt(), llvm::PPCTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), instCombineSVECondLast(), optimizeVectorResizeWithIntegerBitCasts(), and simplifyX86MaskedStore().
|
inline |
Definition at line 2258 of file IRBuilder.h.
References CreateBitCast(), CreateIntToPtr(), CreatePtrToInt(), llvm::Type::isIntOrIntVectorTy(), and llvm::Type::isPtrOrPtrVectorTy().
Referenced by CreateAggregateCast(), and instCombineSVEDupqLane().
|
inline |
Create an unconditional 'br label X' instruction.
Definition at line 1194 of file IRBuilder.h.
References llvm::BranchInst::Create(), and Insert().
Referenced by llvm::createSanitizerCtorAndInitFunctions(), llvm::orc::IRSpeculationLayer::emit(), foldMemChr(), and insertLoopExpansion().
|
inline |
Definition at line 2508 of file IRBuilder.h.
References CreateCall().
|
inline |
Definition at line 2502 of file IRBuilder.h.
|
inline |
Definition at line 2491 of file IRBuilder.h.
References llvm::CallInst::Create(), FMF, Insert(), llvm::isa(), IsFPConstrained, and setConstrainedFPCallAttr().
|
inline |
Definition at line 2480 of file IRBuilder.h.
Referenced by CreateAssumption(), CreateCall(), CreateConstrainedFPCall(), CreateFree(), CreateLaunderInvariantGroup(), CreateMalloc(), llvm::orc::ReOptimizeLayer::createReoptimizeCall(), llvm::createSanitizerCtorAndInitFunctions(), CreateStripInvariantGroup(), llvm::orc::IRSpeculationLayer::emit(), llvm::AMDGPU::generateCrashCode(), llvm::memtag::getAndroidSlotPtr(), llvm::TargetLoweringBase::getSafeStackPointerLocation(), InsertCall(), insertCallBeforeInstruction(), llvm::lowerGlobalIFuncUsersAsGlobalCtor(), llvm::lowerUnaryVectorIntrinsicAsLoop(), replaceWithTLIFunction(), llvm::GCNTTIImpl::simplifyAMDGCNLaneIntrinsicDemanded(), UseTlsOffset(), and useTpOffset().
|
inline |
Definition at line 1302 of file IRBuilder.h.
References CreateCallBr().
|
inline |
Definition at line 1295 of file IRBuilder.h.
|
inline |
Definition at line 1284 of file IRBuilder.h.
References llvm::CallBrInst::Create(), and Insert().
|
inline |
Create a callbr instruction.
Definition at line 1276 of file IRBuilder.h.
Referenced by CreateCallBr().
|
inline |
Definition at line 2210 of file IRBuilder.h.
Referenced by CreateAddrSpaceCast(), CreateBitCast(), CreateFPCast(), CreateFPExtFMF(), CreateFPToSI(), CreateFPToUI(), CreateFPTruncFMF(), CreateIntCast(), CreateIntToPtr(), CreatePtrToAddr(), CreatePtrToInt(), CreateSExt(), CreateSExtOrBitCast(), CreateSIToFP(), CreateTruncOrBitCast(), and CreateZExtOrBitCast().
|
inline |
Definition at line 1327 of file IRBuilder.h.
References llvm::CatchPadInst::Create(), and Insert().
|
inline |
Definition at line 1338 of file IRBuilder.h.
References BB, llvm::CatchReturnInst::Create(), and Insert().
|
inline |
Definition at line 1320 of file IRBuilder.h.
References llvm::CatchSwitchInst::Create(), and Insert().
|
inline |
Definition at line 1332 of file IRBuilder.h.
|
inline |
Definition at line 1315 of file IRBuilder.h.
References llvm::CleanupReturnInst::Create(), and Insert().
|
inline |
Definition at line 2435 of file IRBuilder.h.
References CreateFCmp(), CreateICmp(), llvm::CmpInst::isFPPredicate(), LHS, and RHS.
|
inline |
Create a conditional 'br Cond, TrueDest, FalseDest' instruction.
Copy branch meta data if available.
Definition at line 1209 of file IRBuilder.h.
References Cond, llvm::Instruction::copyMetadata(), llvm::BranchInst::Create(), and Insert().
|
inline |
Create a conditional 'br Cond, TrueDest, FalseDest' instruction.
Definition at line 1200 of file IRBuilder.h.
References Cond, llvm::BranchInst::Create(), and Insert().
Referenced by buildPartialInvariantUnswitchConditionalBranch(), buildPartialUnswitchConditionalBranch(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), llvm::createSanitizerCtorAndInitFunctions(), llvm::orc::IRSpeculationLayer::emit(), insertLoopExpansion(), and llvm::lowerUnaryVectorIntrinsicAsLoop().
|
inline |
Definition at line 1957 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt32Ty(), and llvm::GEPNoWrapFlags::none().
Referenced by llvm::memtag::getAndroidSlotPtr(), llvm::memtag::getDarwinSlotPtr(), UseTlsOffset(), and useTpOffset().
|
inline |
Definition at line 1988 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt64Ty(), and llvm::GEPNoWrapFlags::none().
|
inline |
Definition at line 1969 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt32Ty(), and llvm::GEPNoWrapFlags::none().
Referenced by CreateStructGEP().
|
inline |
Definition at line 2000 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt64Ty(), and llvm::GEPNoWrapFlags::none().
|
inline |
Definition at line 1963 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt32Ty(), and llvm::GEPNoWrapFlags::inBounds().
|
inline |
Definition at line 1994 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt64Ty(), and llvm::GEPNoWrapFlags::inBounds().
|
inline |
Definition at line 1979 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt32Ty(), and llvm::GEPNoWrapFlags::inBounds().
Referenced by llvm::lowerGlobalIFuncUsersAsGlobalCtor().
|
inline |
Definition at line 2009 of file IRBuilder.h.
References Context, CreateGEP(), llvm::Type::getInt64Ty(), and llvm::GEPNoWrapFlags::inBounds().
| CallInst * IRBuilderBase::CreateConstrainedFPBinOp | ( | Intrinsic::ID | ID, |
| Value * | L, | ||
| Value * | R, | ||
| FMFSource | FMFSource = {}, | ||
| const Twine & | Name = "", | ||
| MDNode * | FPMathTag = nullptr, | ||
| std::optional< RoundingMode > | Rounding = std::nullopt, | ||
| std::optional< fp::ExceptionBehavior > | Except = std::nullopt ) |
Definition at line 881 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateIntrinsic(), FMF, llvm::FMFSource::get(), and setConstrainedFPCallAttr().
Referenced by CreateFAddFMF(), CreateFDivFMF(), CreateFMulFMF(), CreateFRemFMF(), and CreateFSubFMF().
| CallInst * IRBuilderBase::CreateConstrainedFPCall | ( | Function * | Callee, |
| ArrayRef< Value * > | Args, | ||
| const Twine & | Name = "", | ||
| std::optional< RoundingMode > | Rounding = std::nullopt, | ||
| std::optional< fp::ExceptionBehavior > | Except = std::nullopt ) |
Definition at line 1000 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateCall(), llvm::Intrinsic::hasConstrainedFPRoundingModeOperand(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), and setConstrainedFPCallAttr().
| CallInst * IRBuilderBase::CreateConstrainedFPCast | ( | Intrinsic::ID | ID, |
| Value * | V, | ||
| Type * | DestTy, | ||
| FMFSource | FMFSource = {}, | ||
| const Twine & | Name = "", | ||
| MDNode * | FPMathTag = nullptr, | ||
| std::optional< RoundingMode > | Rounding = std::nullopt, | ||
| std::optional< fp::ExceptionBehavior > | Except = std::nullopt ) |
Definition at line 947 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateIntrinsic(), FMF, llvm::FMFSource::get(), llvm::Intrinsic::hasConstrainedFPRoundingModeOperand(), llvm::isa(), and setConstrainedFPCallAttr().
Referenced by CreateFPExtFMF(), CreateFPToSI(), CreateFPToUI(), CreateFPTruncFMF(), CreateSIToFP(), and CreateUIToFP().
| CallInst * IRBuilderBase::CreateConstrainedFPCmp | ( | Intrinsic::ID | ID, |
| CmpInst::Predicate | P, | ||
| Value * | L, | ||
| Value * | R, | ||
| const Twine & | Name = "", | ||
| std::optional< fp::ExceptionBehavior > | Except = std::nullopt ) |
Definition at line 988 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateIntrinsic(), P, and setConstrainedFPCallAttr().
| CallInst * IRBuilderBase::CreateConstrainedFPIntrinsic | ( | Intrinsic::ID | ID, |
| ArrayRef< Type * > | Types, | ||
| ArrayRef< Value * > | Args, | ||
| FMFSource | FMFSource, | ||
| const Twine & | Name, | ||
| MDNode * | FPMathTag = nullptr, | ||
| std::optional< RoundingMode > | Rounding = std::nullopt, | ||
| std::optional< fp::ExceptionBehavior > | Except = std::nullopt ) |
This function is like CreateIntrinsic for constrained fp intrinsics.
It sets the rounding mode and exception behavior of the created intrinsic call according to Rounding and Except and it sets FPMathTag as the 'fpmath' metadata, using defaults if a value equals nullopt/null.
Definition at line 897 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateIntrinsic(), FMF, llvm::FMFSource::get(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), and setConstrainedFPCallAttr().
| CallInst * IRBuilderBase::CreateConstrainedFPUnroundedBinOp | ( | Intrinsic::ID | ID, |
| Value * | L, | ||
| Value * | R, | ||
| FMFSource | FMFSource = {}, | ||
| const Twine & | Name = "", | ||
| MDNode * | FPMathTag = nullptr, | ||
| std::optional< fp::ExceptionBehavior > | Except = std::nullopt ) |
Definition at line 917 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateIntrinsic(), FMF, llvm::FMFSource::get(), and setConstrainedFPCallAttr().
|
inline |
Create call to the copysign intrinsic.
Definition at line 1061 of file IRBuilder.h.
|
inline |
Create a call to llvm.experimental_cttz_elts.
Definition at line 1137 of file IRBuilder.h.
References CreateIntrinsic(), and getInt1().
Create an assume intrinsic call that represents an dereferencable assumption on the provided pointer.
Definition at line 1309 of file IRBuilder.cpp.
References assert(), CreateAssumption(), getContext(), llvm::ConstantInt::getTrue(), llvm::Value::getType(), and llvm::isa().
| Value * IRBuilderBase::CreateElementCount | ( | Type * | Ty, |
| ElementCount | EC ) |
Create an expression which evaluates to the number of elements in EC at runtime.
This can result in poison if type Ty is not big enough to hold the value.
Definition at line 124 of file IRBuilder.cpp.
References CreateVScaleMultiple().
Referenced by instCombineSMECntsd(), instCombineSVECntElts(), llvm::lowerUnaryVectorIntrinsicAsLoop(), and llvm::SplitBlockAndInsertForEachLane().
| CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemCpy | ( | Value * | Dst, |
| Align | DstAlign, | ||
| Value * | Src, | ||
| Align | SrcAlign, | ||
| Value * | Size, | ||
| uint32_t | ElementSize, | ||
| const AAMDNodes & | AAInfo = AAMDNodes() ) |
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 alias metadata is specified, it will be added to the instruction.
Definition at line 243 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), llvm::cast(), CreateIntrinsic(), getInt32(), and Size.
| CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemMove | ( | Value * | Dst, |
| Align | DstAlign, | ||
| Value * | Src, | ||
| Align | SrcAlign, | ||
| Value * | Size, | ||
| uint32_t | ElementSize, | ||
| const AAMDNodes & | AAInfo = AAMDNodes() ) |
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 alias metadata is specified, it will be added to the instruction.
Definition at line 342 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), assert(), CreateIntrinsic(), llvm::Value::getContext(), getInt32(), llvm::Attribute::getWithAlignment(), llvm::Instruction::setAAMetadata(), and Size.
|
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 alias metadata is specified, it will be added to the instruction.
Definition at line 650 of file IRBuilder.h.
References CreateElementUnorderedAtomicMemSet(), getInt64(), and Size.
Referenced by CreateElementUnorderedAtomicMemSet().
| CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemSet | ( | Value * | Ptr, |
| Value * | Val, | ||
| Value * | Size, | ||
| Align | Alignment, | ||
| uint32_t | ElementSize, | ||
| const AAMDNodes & | AAInfo = AAMDNodes() ) |
Definition at line 206 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::cast(), CreateIntrinsic(), getInt32(), llvm::Value::getType(), llvm::Instruction::setAAMetadata(), and Size.
|
inline |
Definition at line 1479 of file IRBuilder.h.
References CreateSDiv(), LHS, and RHS.
Referenced by CreatePtrDiff().
|
inline |
Definition at line 1466 of file IRBuilder.h.
References CreateUDiv(), LHS, and RHS.
|
inline |
Definition at line 2549 of file IRBuilder.h.
References CreateExtractElement(), and getInt64().
|
inline |
Definition at line 2542 of file IRBuilder.h.
References llvm::ExtractElementInst::Create(), Folder, and Insert().
Referenced by CreateExtractElement(), llvm::PPCTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), instCombineSVETBL(), llvm::lowerUnaryVectorIntrinsicAsLoop(), llvm::GCNTTIImpl::simplifyAMDGCNLaneIntrinsicDemanded(), simplifyAMDGCNMemoryIntrinsicDemanded(), and simplifyX86FPMaxMin().
|
inline |
Definition at line 2601 of file IRBuilder.h.
References llvm::ExtractValueInst::Create(), Folder, and Insert().
Referenced by CreateAggregateCast(), and unpackStoreToAggregate().
|
inline |
Create a call to the vector.extract intrinsic.
Definition at line 1104 of file IRBuilder.h.
References CreateExtractVector(), and getInt64().
|
inline |
Create a call to the vector.extract intrinsic.
Definition at line 1096 of file IRBuilder.h.
References CreateIntrinsic(), and llvm::Value::getType().
Referenced by CreateExtractVector(), and llvm::GCNTTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 1616 of file IRBuilder.h.
References CreateFAddFMF().
Referenced by llvm::X86TTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 1621 of file IRBuilder.h.
References CreateConstrainedFPBinOp(), FMF, Folder, llvm::FMFSource::get(), I, Insert(), and IsFPConstrained.
Referenced by CreateFAdd(), and llvm::GCNTTIImpl::instCombineIntrinsic().
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 368 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, and CreateIntrinsic().
|
inline |
Definition at line 2421 of file IRBuilder.h.
Referenced by CreateCmp(), CreateFCmpOEQ(), CreateFCmpOGE(), CreateFCmpOGT(), CreateFCmpOLE(), CreateFCmpOLT(), CreateFCmpONE(), CreateFCmpORD(), CreateFCmpUEQ(), CreateFCmpUGE(), CreateFCmpUGT(), CreateFCmpULE(), CreateFCmpULT(), CreateFCmpUNE(), and CreateFCmpUNO().
|
inline |
Definition at line 2429 of file IRBuilder.h.
|
inline |
Definition at line 2341 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_OEQ, LHS, and RHS.
|
inline |
Definition at line 2351 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_OGE, LHS, and RHS.
|
inline |
Definition at line 2346 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_OGT, LHS, and RHS.
|
inline |
Definition at line 2361 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_OLE, LHS, and RHS.
|
inline |
Definition at line 2356 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_OLT, LHS, and RHS.
|
inline |
Definition at line 2366 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_ONE, LHS, and RHS.
|
inline |
Definition at line 2371 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_ORD, LHS, and RHS.
|
inline |
Definition at line 2445 of file IRBuilder.h.
|
inline |
Definition at line 2381 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_UEQ, LHS, and RHS.
|
inline |
Definition at line 2391 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_UGE, LHS, and RHS.
|
inline |
Definition at line 2386 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_UGT, LHS, and RHS.
|
inline |
Definition at line 2401 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_ULE, LHS, and RHS.
|
inline |
Definition at line 2396 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_ULT, LHS, and RHS.
|
inline |
Definition at line 2406 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_UNE, LHS, and RHS.
|
inline |
Definition at line 2376 of file IRBuilder.h.
References CreateFCmp(), llvm::CmpInst::FCMP_UNO, LHS, and RHS.
|
inline |
Definition at line 1673 of file IRBuilder.h.
References CreateFDivFMF().
Referenced by llvm::X86TTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 1678 of file IRBuilder.h.
References CreateConstrainedFPBinOp(), FMF, Folder, llvm::FMFSource::get(), I, Insert(), and IsFPConstrained.
Referenced by CreateFDiv().
|
inline |
Definition at line 1898 of file IRBuilder.h.
References Context, Insert(), and llvm::SyncScope::System.
|
inline |
Create call to the fma intrinsic.
Definition at line 1076 of file IRBuilder.h.
|
inline |
Definition at line 1654 of file IRBuilder.h.
References CreateFMulFMF().
Referenced by llvm::X86TTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 1659 of file IRBuilder.h.
References CreateConstrainedFPBinOp(), FMF, Folder, llvm::FMFSource::get(), I, Insert(), and IsFPConstrained.
Referenced by CreateFMul(), and llvm::GCNTTIImpl::instCombineIntrinsic().
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 373 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, and CreateIntrinsic().
|
inline |
Definition at line 1797 of file IRBuilder.h.
References CreateFNegFMF().
|
inline |
Definition at line 1802 of file IRBuilder.h.
References FMF, Folder, llvm::FMFSource::get(), and Insert().
Referenced by CreateFNeg().
|
inline |
Definition at line 2270 of file IRBuilder.h.
References CreateCast(), and llvm::Type::getScalarSizeInBits().
|
inline |
Definition at line 2149 of file IRBuilder.h.
References CreateFPExtFMF().
|
inline |
Definition at line 2154 of file IRBuilder.h.
References CreateCast(), CreateConstrainedFPCast(), and IsFPConstrained.
Referenced by CreateFPExt().
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 418 of file IRBuilder.cpp.
Create a vector float max reduction intrinsic of the source vector.
Definition at line 410 of file IRBuilder.cpp.
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 422 of file IRBuilder.cpp.
Create a vector float min reduction intrinsic of the source vector.
Definition at line 414 of file IRBuilder.cpp.
|
inline |
Definition at line 2107 of file IRBuilder.h.
References CreateCast(), CreateConstrainedFPCast(), and IsFPConstrained.
|
inline |
Definition at line 2100 of file IRBuilder.h.
References CreateCast(), CreateConstrainedFPCast(), and IsFPConstrained.
|
inline |
Definition at line 2134 of file IRBuilder.h.
References CreateFPTruncFMF().
|
inline |
Definition at line 2139 of file IRBuilder.h.
References CreateCast(), CreateConstrainedFPCast(), and IsFPConstrained.
Referenced by CreateFPTrunc().
| CallInst * IRBuilderBase::CreateFree | ( | Value * | Source, |
| ArrayRef< OperandBundleDef > | Bundles = {} ) |
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 323 of file IRBuilder.cpp.
References assert(), BB, CreateCall(), llvm::dyn_cast(), F, llvm::FunctionCallee::getCallee(), llvm::PointerType::getUnqual(), and llvm::Type::getVoidTy().
Definition at line 2620 of file IRBuilder.h.
References Insert().
Referenced by llvm::addDiffRuntimeChecks(), and buildPartialUnswitchConditionalBranch().
|
inline |
Definition at line 1692 of file IRBuilder.h.
References CreateFRemFMF().
|
inline |
Definition at line 1697 of file IRBuilder.h.
References CreateConstrainedFPBinOp(), FMF, Folder, llvm::FMFSource::get(), I, Insert(), and IsFPConstrained.
Referenced by CreateFRem().
|
inline |
Definition at line 1635 of file IRBuilder.h.
References CreateFSubFMF().
Referenced by llvm::X86TTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 1640 of file IRBuilder.h.
References CreateConstrainedFPBinOp(), FMF, Folder, llvm::FMFSource::get(), I, Insert(), and IsFPConstrained.
Referenced by CreateFSub().
Create a call to the experimental.gc.pointer.base intrinsic to get the base pointer for the specified derived pointer.
Definition at line 823 of file IRBuilder.cpp.
References CreateIntrinsic(), and llvm::Value::getType().
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 830 of file IRBuilder.cpp.
References CreateIntrinsic(), and llvm::Value::getType().
| 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 813 of file IRBuilder.cpp.
References CreateIntrinsic(), and getInt32().
| 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 804 of file IRBuilder.cpp.
References CreateIntrinsic().
| 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 735 of file IRBuilder.cpp.
References CreateGCStatepointCallCommon(), and llvm::None.
| 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 715 of file IRBuilder.cpp.
References CreateGCStatepointCallCommon(), and llvm::None.
| 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 724 of file IRBuilder.cpp.
References CreateGCStatepointCallCommon().
| 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 793 of file IRBuilder.cpp.
References CreateGCStatepointInvokeCommon(), and llvm::None.
| 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 771 of file IRBuilder.cpp.
References CreateGCStatepointInvokeCommon(), and llvm::None.
| 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 782 of file IRBuilder.cpp.
References CreateGCStatepointInvokeCommon().
|
inline |
Definition at line 1944 of file IRBuilder.h.
References llvm::GetElementPtrInst::Create(), Folder, Insert(), and llvm::GEPNoWrapFlags::none().
Referenced by CreateConstGEP1_32(), CreateConstGEP1_64(), CreateConstGEP2_32(), CreateConstGEP2_64(), CreateConstInBoundsGEP1_32(), CreateConstInBoundsGEP1_64(), CreateConstInBoundsGEP2_32(), CreateConstInBoundsGEP2_64(), CreateInBoundsGEP(), CreateInBoundsPtrAdd(), CreatePtrAdd(), instCombineLD1GatherIndex(), and instCombineST1ScatterIndex().
| GlobalVariable * IRBuilderBase::CreateGlobalString | ( | StringRef | Str, |
| const Twine & | Name = "", | ||
| unsigned | AddressSpace = 0, | ||
| Module * | M = nullptr, | ||
| bool | AddNull = true ) |
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 44 of file IRBuilder.cpp.
References BB, Context, getInt8Ty(), llvm::ConstantDataArray::getString(), llvm::Value::getType(), llvm::GlobalValue::Global, llvm::GlobalValue::NotThreadLocal, and llvm::GlobalValue::PrivateLinkage.
|
inline |
Definition at line 2411 of file IRBuilder.h.
References Folder, Insert(), LHS, P, and RHS.
Referenced by CreateCmp(), CreateICmpEQ(), CreateICmpNE(), CreateICmpSGE(), CreateICmpSGT(), CreateICmpSLE(), CreateICmpSLT(), CreateICmpUGE(), CreateICmpUGT(), CreateICmpULE(), CreateICmpULT(), foldCtpop(), foldICmpWithLowBitMaskedVal(), llvm::lowerUnaryVectorIntrinsicAsLoop(), RunTermFold(), and llvm::UnrollRuntimeLoopRemainder().
|
inline |
Definition at line 2301 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_EQ, LHS, and RHS.
Referenced by CreateIsNull(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), llvm::orc::IRSpeculationLayer::emit(), llvm::orc::ReOptimizeLayer::reoptimizeIfCallFrequent(), and simplifyShiftSelectingPackedElement().
|
inline |
Definition at line 2305 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_NE, LHS, and RHS.
Referenced by CreateIsNotNull(), llvm::createSanitizerCtorAndInitFunctions(), insertLoopExpansion(), and llvm::GCNTTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 2329 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_SGE, LHS, and RHS.
Referenced by llvm::AMDGPU::createSlowPathCmp().
|
inline |
Definition at line 2325 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_SGT, LHS, and RHS.
Referenced by CreateIsNotNeg(), and llvm::X86TTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 2337 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_SLE, LHS, and RHS.
|
inline |
Definition at line 2333 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_SLT, LHS, and RHS.
Referenced by llvm::addRuntimeChecks(), CreateIsNeg(), and getBoundsCheckCond().
|
inline |
Definition at line 2313 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_UGE, LHS, and RHS.
|
inline |
Definition at line 2309 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_UGT, LHS, and RHS.
|
inline |
Definition at line 2321 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_ULE, LHS, and RHS.
|
inline |
Definition at line 2317 of file IRBuilder.h.
References CreateICmp(), llvm::CmpInst::ICMP_ULT, LHS, and RHS.
Referenced by llvm::addDiffRuntimeChecks(), llvm::addRuntimeChecks(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), getBoundsCheckCond(), and insertLoopExpansion().
|
inline |
Definition at line 1952 of file IRBuilder.h.
References CreateGEP(), and llvm::GEPNoWrapFlags::inBounds().
Referenced by llvm::createMemCpyLoopKnownSize(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), unpackLoadToAggregate(), and unpackStoreToAggregate().
|
inline |
Definition at line 2030 of file IRBuilder.h.
References CreateGEP(), getInt8Ty(), llvm::GEPNoWrapFlags::inBounds(), and llvm::Offset.
Referenced by foldMemChr(), unpackLoadToAggregate(), and unpackStoreToAggregate().
|
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 1233 of file IRBuilder.h.
References llvm::IndirectBrInst::Create(), and Insert().
|
inline |
Definition at line 2559 of file IRBuilder.h.
References CreateInsertElement(), and llvm::PoisonValue::get().
|
inline |
Definition at line 2554 of file IRBuilder.h.
References CreateInsertElement(), and llvm::PoisonValue::get().
Referenced by CreateInsertElement(), CreateInsertElement(), CreateInsertElement(), CreateVectorSplat(), llvm::GCNTTIImpl::instCombineIntrinsic(), llvm::PPCTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), instCombineSVEDup(), instCombineSVEDupqLane(), llvm::lowerUnaryVectorIntrinsicAsLoop(), optimizeIntegerToVectorInsertions(), llvm::GCNTTIImpl::simplifyAMDGCNLaneIntrinsicDemanded(), simplifyAMDGCNMemoryIntrinsicDemanded(), and simplifyX86FPMaxMin().
|
inline |
Definition at line 2571 of file IRBuilder.h.
References CreateInsertElement(), and getInt64().
|
inline |
Definition at line 2564 of file IRBuilder.h.
References llvm::InsertElementInst::Create(), Folder, and Insert().
|
inline |
Definition at line 2608 of file IRBuilder.h.
References llvm::InsertValueInst::Create(), Folder, and Insert().
Referenced by CreateAggregateCast(), CreateAggregateRet(), expandFromPrimitiveShadowRecursive(), and unpackLoadToAggregate().
|
inline |
Create a call to the vector.extract intrinsic.
Definition at line 1118 of file IRBuilder.h.
References CreateInsertVector(), and getInt64().
|
inline |
Create a call to the vector.insert intrinsic.
Definition at line 1110 of file IRBuilder.h.
References CreateIntrinsic(), and llvm::Value::getType().
Referenced by CreateInsertVector(), instCombineSVEDupqLane(), and instCombineSVEUzp1().
References LLVM_ABI.
|
inline |
Definition at line 2249 of file IRBuilder.h.
References CreateCast(), and llvm::Type::getScalarSizeInBits().
Referenced by CreateMalloc(), llvm::AMDGPU::createSlowPathCmp(), instCombineSVEUnpack(), and simplifyAllocaArraySize().
Create a vector integer max reduction intrinsic of the source vector.
Definition at line 398 of file IRBuilder.cpp.
Create a vector integer min reduction intrinsic of the source vector.
Definition at line 404 of file IRBuilder.cpp.
| CallInst * IRBuilderBase::CreateIntrinsic | ( | Intrinsic::ID | ID, |
| ArrayRef< Type * > | Types, | ||
| ArrayRef< Value * > | Args, | ||
| FMFSource | FMFSource = {}, | ||
| 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 856 of file IRBuilder.cpp.
References BB, and llvm::Intrinsic::getOrInsertDeclaration().
Referenced by addBoundsChecking(), llvm::VNCoercion::coerceAvailableValueToLoadType(), CreateArithmeticFence(), CreateConstrainedFPBinOp(), CreateConstrainedFPCast(), CreateConstrainedFPCmp(), CreateConstrainedFPIntrinsic(), CreateConstrainedFPUnroundedBinOp(), CreateCountTrailingZeroElems(), CreateElementUnorderedAtomicMemCpy(), CreateElementUnorderedAtomicMemMove(), CreateElementUnorderedAtomicMemSet(), CreateExtractVector(), CreateFAddReduce(), createFFSIntrinsic(), CreateFMulReduce(), CreateGCGetPointerBase(), CreateGCGetPointerOffset(), CreateGCRelocate(), CreateGCResult(), CreateInsertVector(), CreateInvariantStart(), createIsFPClass(), CreateLifetimeEnd(), CreateLifetimeStart(), CreateMemSet(), CreateMemSetInline(), CreateMemTransferInst(), CreateNoAliasScopeDeclaration(), createNVVMInternalAddrspaceWrap(), createPopcntIntrinsic(), CreatePreserveArrayAccessIndex(), CreatePreserveStructAccessIndex(), CreatePreserveUnionAccessIndex(), CreateStackRestore(), CreateStackSave(), CreateStepVector(), CreateStructuredGEP(), CreateThreadLocalAddress(), CreateVectorInterleave(), CreateVectorSpliceLeft(), CreateVectorSpliceRight(), CreateVScale(), foldCtpop(), foldCttzCtlz(), llvm::AMDGPU::genAMDGPUReportBlock(), llvm::memtag::getDarwinSlotPtr(), llvm::memtag::getFP(), InsertTrap(), llvm::ARMTTIImpl::instCombineIntrinsic(), llvm::GCNTTIImpl::instCombineIntrinsic(), instCombineRDFFR(), instCombineSVECmpNE(), instCombineSVECondLast(), instCombineSVELast(), instCombineSVEPTest(), instCombineSVESDIV(), instCombineSVESrshl(), instCombineSVEUxt(), instCombineSVEVectorFuseMulAddSub(), instCombineWhilelo(), lowerIntrinsicToFunction(), lowerPtrAnnotation(), modifyIntrinsicCall(), llvm::memtag::readRegister(), simplifyAMDGCNMemoryIntrinsicDemanded(), and tryCombineFromSVBoolBinOp().
|
inline |
Create a call to non-overloaded intrinsic ID with Args.
If FMFSource is provided, copy fast-math-flags from that instruction to the intrinsic.
Definition at line 1009 of file IRBuilder.h.
| CallInst * IRBuilderBase::CreateIntrinsic | ( | Type * | RetTy, |
| Intrinsic::ID | ID, | ||
| ArrayRef< Value * > | Args, | ||
| FMFSource | FMFSource = {}, | ||
| const Twine & | Name = "" ) |
Create a call to intrinsic ID with RetTy and Args.
If FMFSource is provided, copy fast-math-flags from that instruction to the intrinsic.
Definition at line 866 of file IRBuilder.cpp.
References BB, llvm::Intrinsic::getOrInsertDeclaration(), I, llvm::SmallVectorTemplateBase< T, bool >::push_back(), and llvm::SmallVectorImpl< T >::reserve().
|
inline |
Definition at line 2171 of file IRBuilder.h.
References CreateCast().
Referenced by llvm::VNCoercion::coerceAvailableValueToLoadType(), CreateBitOrPointerCast(), llvm::memtag::getDarwinSlotPtr(), llvm::AMDGPU::instrumentAddress(), and llvm::AMDGPU::instrumentAddressImpl().
| 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 438 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), CreateIntrinsic(), getInt64(), getInt64Ty(), llvm::Value::getType(), llvm::isa(), and Size.
|
inline |
Definition at line 1260 of file IRBuilder.h.
References CreateInvoke().
|
inline |
Definition at line 1268 of file IRBuilder.h.
|
inline |
Create an invoke instruction.
Definition at line 1238 of file IRBuilder.h.
References llvm::InvokeInst::Create(), II, Insert(), IsFPConstrained, and setConstrainedFPCallAttr().
Referenced by CreateInvoke().
|
inline |
Definition at line 1249 of file IRBuilder.h.
Definition at line 1270 of file IRBuilder.cpp.
References CreateIntrinsic(), getInt32(), llvm::Value::getType(), and llvm::Test.
Return a boolean value testing if Arg < 0.
Definition at line 2639 of file IRBuilder.h.
References CreateICmpSLT(), llvm::Constant::getNullValue(), and llvm::Value::getType().
Return a boolean value testing if Arg > -1.
Definition at line 2644 of file IRBuilder.h.
References CreateICmpSGT(), llvm::Constant::getAllOnesValue(), and llvm::Value::getType().
Return a boolean value testing if Arg != 0.
Definition at line 2634 of file IRBuilder.h.
References CreateICmpNE(), llvm::Constant::getNullValue(), and llvm::Value::getType().
Referenced by ConnectEpilog(), llvm::AMDGPU::genAMDGPUReportBlock(), and llvm::AMDGPU::instrumentAddressImpl().
Return a boolean value testing if Arg == 0.
Definition at line 2629 of file IRBuilder.h.
References CreateICmpEQ(), llvm::Constant::getNullValue(), and llvm::Value::getType().
|
inline |
Definition at line 2615 of file IRBuilder.h.
References llvm::LandingPadInst::Create(), and Insert().
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 1070 of file IRBuilder.cpp.
References assert(), BB, CreateCall(), llvm::Function::getFunctionType(), llvm::Intrinsic::getOrInsertDeclaration(), llvm::FunctionType::getParamType(), llvm::Function::getReturnType(), llvm::Value::getType(), and llvm::isa().
Referenced by simplifyInvariantGroupIntrinsic().
|
inline |
Create call to the ldexp intrinsic.
Definition at line 1068 of file IRBuilder.h.
Create a lifetime.end intrinsic.
Definition at line 432 of file IRBuilder.cpp.
References assert(), CreateIntrinsic(), llvm::Value::getType(), and llvm::isa().
Create a lifetime.start intrinsic.
Definition at line 426 of file IRBuilder.cpp.
References assert(), CreateIntrinsic(), llvm::Value::getType(), and llvm::isa().
Referenced by llvm::InlineFunctionImpl().
|
inline |
Definition at line 1862 of file IRBuilder.h.
References CreateAlignedLoad().
Provided to resolve 'CreateLoad(Ty, Ptr, "...")' correctly, instead of converting the string to 'bool' for the isVolatile parameter.
Definition at line 1854 of file IRBuilder.h.
References CreateAlignedLoad().
Referenced by llvm::orc::IRSpeculationLayer::emit(), instCombineSVELD1(), and llvm::orc::ReOptimizeLayer::reoptimizeIfCallFrequent().
|
inline |
Definition at line 1858 of file IRBuilder.h.
References CreateAlignedLoad().
|
inline |
Definition at line 1728 of file IRBuilder.h.
References assert(), CreateSelect(), llvm::Constant::getNullValue(), llvm::Value::getType(), and llvm::Type::isIntOrIntVectorTy().
Referenced by CreateLogicalOp().
|
inline |
Definition at line 1743 of file IRBuilder.h.
References CreateLogicalAnd(), CreateLogicalOr(), llvm_unreachable, and Opc.
Definition at line 1758 of file IRBuilder.h.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), and CreateLogicalOr().
|
inline |
Definition at line 1736 of file IRBuilder.h.
References assert(), CreateSelect(), llvm::Constant::getAllOnesValue(), llvm::Value::getType(), and llvm::Type::isIntOrIntVectorTy().
Referenced by CreateLogicalOp(), and CreateLogicalOr().
|
inline |
Definition at line 1525 of file IRBuilder.h.
References CreateLShr(), LHS, and RHS.
|
inline |
Definition at line 1530 of file IRBuilder.h.
References CreateLShr(), LHS, and RHS.
|
inline |
Definition at line 1516 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by llvm::VNCoercion::coerceAvailableValueToLoadType(), CreateLShr(), CreateLShr(), getShiftedValue(), llvm::GCNTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), llvm::AMDGPU::instrumentAddress(), lowerFunnelShifts(), and llvm::AMDGPU::memToShadow().
| CallInst * IRBuilderBase::CreateMalloc | ( | Type * | IntPtrTy, |
| Type * | AllocTy, | ||
| Value * | AllocSize, | ||
| Value * | ArraySize, | ||
| ArrayRef< OperandBundleDef > | OpB, | ||
| Function * | MallocF = nullptr, | ||
| const Twine & | Name = "" ) |
Definition at line 271 of file IRBuilder.cpp.
References assert(), BB, Context, CreateCall(), CreateIntCast(), CreateMul(), llvm::dyn_cast(), F, llvm::FunctionCallee::getCallee(), llvm::Value::getType(), llvm::PointerType::getUnqual(), isConstantOne(), llvm::Type::isVoidTy(), llvm::CallBase::setCallingConv(), and llvm::CallInst::setTailCall().
Referenced by CreateMalloc().
| 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:
Definition at line 314 of file IRBuilder.cpp.
References CreateMalloc().
| CallInst * IRBuilderBase::CreateMaskedCompressStore | ( | Value * | Val, |
| Value * | Ptr, | ||
| MaybeAlign | Align, | ||
| 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 Align - alignment of Ptr Mask - vector of booleans which indicates what vector lanes should be accessed in memory.
Definition at line 640 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), assert(), llvm::Value::getContext(), llvm::Value::getType(), llvm::Attribute::getWithAlignment(), and llvm::Type::isVectorTy().
| CallInst * IRBuilderBase::CreateMaskedExpandLoad | ( | Type * | Ty, |
| Value * | Ptr, | ||
| MaybeAlign | Align, | ||
| 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 Align - alignment of Ptr 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 617 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), assert(), llvm::PoisonValue::get(), llvm::Value::getContext(), and llvm::Attribute::getWithAlignment().
| 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 555 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), assert(), llvm::cast(), llvm::PoisonValue::get(), getAllOnesMask(), llvm::Value::getContext(), llvm::Value::getType(), and llvm::Attribute::getWithAlignment().
| 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 500 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), assert(), llvm::cast(), llvm::PoisonValue::get(), llvm::Value::getContext(), llvm::Value::getType(), and llvm::Attribute::getWithAlignment().
Referenced by instCombineLD1GatherIndex(), instCombineSVELD1(), and simplifyX86MaskedLoad().
| 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 588 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), llvm::cast(), llvm::Data, getAllOnesMask(), llvm::Value::getContext(), llvm::Value::getType(), and llvm::Attribute::getWithAlignment().
| 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 522 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::CallBase::addParamAttr(), assert(), llvm::cast(), llvm::Value::getContext(), llvm::Value::getType(), llvm::Attribute::getWithAlignment(), and llvm::Type::isVectorTy().
Referenced by instCombineST1ScatterIndex(), instCombineSVEST1(), and simplifyX86MaskedStore().
|
inline |
Create call to the maximum intrinsic.
Definition at line 1044 of file IRBuilder.h.
References CreateBinaryIntrinsic(), LHS, and RHS.
|
inline |
Create call to the maximum intrinsic.
Definition at line 1055 of file IRBuilder.h.
References CreateBinaryIntrinsic(), LHS, and RHS.
Referenced by llvm::GCNTTIImpl::instCombineIntrinsic().
|
inline |
Create call to the maxnum intrinsic.
Definition at line 1027 of file IRBuilder.h.
Referenced by llvm::GCNTTIImpl::instCombineIntrinsic(), and simplifyX86FPMaxMin().
|
inline |
Create and insert a memcpy between the specified pointers.
If the pointers aren't i8*, they will be converted. If alias metadata is specified, it will be added to the instruction. and noalias tags.
Definition at line 686 of file IRBuilder.h.
References CreateMemCpy(), getInt64(), and Size.
Referenced by CreateMemCpy().
|
inline |
Definition at line 700 of file IRBuilder.h.
References CreateMemTransferInst(), and Size.
|
inline |
Definition at line 708 of file IRBuilder.h.
References CreateMemTransferInst(), and Size.
|
inline |
Definition at line 728 of file IRBuilder.h.
References CreateMemMove(), getInt64(), and Size.
Referenced by CreateMemMove().
|
inline |
Definition at line 736 of file IRBuilder.h.
References CreateMemTransferInst(), and Size.
|
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 alias metadata is specified, it will be added to the instruction.
Definition at line 629 of file IRBuilder.h.
References CreateMemSet(), getInt64(), and Size.
Referenced by CreateMemSet(), and lowerIntrinsicToFunction().
| CallInst * IRBuilderBase::CreateMemSet | ( | Value * | Ptr, |
| Value * | Val, | ||
| Value * | Size, | ||
| MaybeAlign | Align, | ||
| bool | isVolatile = false, | ||
| const AAMDNodes & | AAInfo = AAMDNodes() ) |
Definition at line 177 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::cast(), CreateIntrinsic(), getInt1(), llvm::Value::getType(), llvm::Instruction::setAAMetadata(), and Size.
| CallInst * IRBuilderBase::CreateMemSetInline | ( | Value * | Dst, |
| MaybeAlign | DstAlign, | ||
| Value * | Val, | ||
| Value * | Size, | ||
| bool | IsVolatile = false, | ||
| const AAMDNodes & | AAInfo = AAMDNodes() ) |
Definition at line 191 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, llvm::cast(), CreateIntrinsic(), getInt1(), llvm::Instruction::setAAMetadata(), and Size.
| CallInst * IRBuilderBase::CreateMemTransferInst | ( | Intrinsic::ID | IntrID, |
| Value * | Dst, | ||
| MaybeAlign | DstAlign, | ||
| Value * | Src, | ||
| MaybeAlign | SrcAlign, | ||
| Value * | Size, | ||
| bool | isVolatile = false, | ||
| const AAMDNodes & | AAInfo = AAMDNodes() ) |
Definition at line 221 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), llvm::cast(), CreateIntrinsic(), getInt1(), and Size.
Referenced by CreateMemCpy(), CreateMemCpyInline(), and CreateMemMove().
|
inline |
Create call to the minimum intrinsic.
Definition at line 1039 of file IRBuilder.h.
References CreateBinaryIntrinsic(), LHS, and RHS.
|
inline |
Create call to the minimumnum intrinsic.
Definition at line 1049 of file IRBuilder.h.
References CreateBinaryIntrinsic(), LHS, and RHS.
Referenced by llvm::GCNTTIImpl::instCombineIntrinsic().
|
inline |
Create call to the minnum intrinsic.
Definition at line 1015 of file IRBuilder.h.
Referenced by llvm::GCNTTIImpl::instCombineIntrinsic(), and simplifyX86FPMaxMin().
|
inline |
Definition at line 1440 of file IRBuilder.h.
References Folder, LHS, and RHS.
Referenced by llvm::addDiffRuntimeChecks(), CreateAllocationSize(), CreateMalloc(), CreateNSWMul(), and CreateNUWMul().
Create a vector int mul reduction intrinsic of the source vector.
Definition at line 382 of file IRBuilder.cpp.
| 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 932 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), CreateBinOp(), CreateUnOp(), llvm::Instruction::isBinaryOp(), llvm::Instruction::isUnaryOp(), llvm_unreachable, and Opc.
|
inline |
Definition at line 1788 of file IRBuilder.h.
References CreateSub(), and llvm::Constant::getNullValue().
Referenced by CreateNSWNeg().
|
inline |
Definition at line 876 of file IRBuilder.h.
References Context, CreateNoAliasScopeDeclaration(), and llvm::MetadataAsValue::get().
| Instruction * IRBuilderBase::CreateNoAliasScopeDeclaration | ( | Value * | Scope | ) |
Create a llvm.experimental.noalias.scope.decl intrinsic call.
Definition at line 486 of file IRBuilder.cpp.
References CreateIntrinsic().
Referenced by CreateNoAliasScopeDeclaration().
Definition at line 1812 of file IRBuilder.h.
References CreateXor(), and llvm::Constant::getAllOnesValue().
Referenced by freelyInvert(), matchDeMorgansLaws(), mergeConditionalStoreToAddress(), and simplifyUsingControlFlow().
|
inline |
Definition at line 1415 of file IRBuilder.h.
References CreateAdd(), LHS, and RHS.
|
inline |
Definition at line 1449 of file IRBuilder.h.
References CreateMul(), LHS, and RHS.
Definition at line 1793 of file IRBuilder.h.
References CreateNeg().
|
inline |
Definition at line 1432 of file IRBuilder.h.
References CreateSub(), LHS, and RHS.
|
inline |
Definition at line 1419 of file IRBuilder.h.
References CreateAdd(), LHS, and RHS.
|
inline |
Definition at line 1453 of file IRBuilder.h.
References CreateMul(), LHS, and RHS.
|
inline |
Definition at line 1436 of file IRBuilder.h.
References CreateSub(), LHS, and RHS.
Definition at line 1594 of file IRBuilder.h.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), and CreateOr().
|
inline |
Definition at line 1586 of file IRBuilder.h.
References CreateOr(), LHS, and RHS.
Definition at line 1590 of file IRBuilder.h.
References CreateOr(), LHS, and RHS.
|
inline |
Definition at line 1576 of file IRBuilder.h.
References llvm::BinaryOperator::CreateDisjoint(), Folder, Insert(), LHS, and RHS.
Referenced by llvm::addDiffRuntimeChecks(), llvm::addRuntimeChecks(), buildPartialUnswitchConditionalBranch(), CreateOr(), CreateOr(), CreateOr(), foldICmpAndXX(), foldICmpOrXX(), getBoundsCheckCond(), lowerFunnelShifts(), and mergeConditionalStoreToAddress().
Create a vector int OR reduction intrinsic of the source vector.
Definition at line 390 of file IRBuilder.cpp.
|
inline |
Definition at line 2466 of file IRBuilder.h.
References llvm::PHINode::Create(), FMF, Insert(), and llvm::isa().
Referenced by createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), expandToSwitch(), foldMemChr(), insertLoopExpansion(), llvm::lowerUnaryVectorIntrinsicAsLoop(), and processPhiNode().
|
inline |
Definition at line 2235 of file IRBuilder.h.
References llvm::CastInst::CreatePointerBitCastOrAddrSpaceCast(), llvm::dyn_cast(), Folder, and Insert().
|
inline |
Definition at line 2223 of file IRBuilder.h.
References llvm::CastInst::CreatePointerCast(), llvm::dyn_cast(), Folder, and Insert().
Referenced by llvm::lowerGlobalIFuncUsersAsGlobalCtor(), and UseTlsOffset().
| Value * IRBuilderBase::CreatePreserveArrayAccessIndex | ( | Type * | ElTy, |
| Value * | Base, | ||
| unsigned | Dimension, | ||
| unsigned | LastIndex, | ||
| MDNode * | DbgInfo ) |
Definition at line 1204 of file IRBuilder.cpp.
References llvm::CallBase::addParamAttr(), assert(), llvm::sampleprof::Base, Context, CreateIntrinsic(), llvm::Attribute::get(), llvm::Value::getContext(), llvm::GetElementPtrInst::getGEPReturnType(), getInt32(), llvm::Type::getInt32Ty(), llvm::isa(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), and llvm::Instruction::setMetadata().
| Value * IRBuilderBase::CreatePreserveStructAccessIndex | ( | Type * | ElTy, |
| Value * | Base, | ||
| unsigned | Index, | ||
| unsigned | FieldIndex, | ||
| MDNode * | DbgInfo ) |
Definition at line 1246 of file IRBuilder.cpp.
References llvm::CallBase::addParamAttr(), assert(), llvm::sampleprof::Base, Context, CreateIntrinsic(), llvm::Attribute::get(), llvm::Value::getContext(), llvm::GetElementPtrInst::getGEPReturnType(), getInt32(), llvm::Type::getInt32Ty(), llvm::isa(), and llvm::Instruction::setMetadata().
| Value * IRBuilderBase::CreatePreserveUnionAccessIndex | ( | Value * | Base, |
| unsigned | FieldIndex, | ||
| MDNode * | DbgInfo ) |
Definition at line 1231 of file IRBuilder.cpp.
References assert(), llvm::sampleprof::Base, CreateIntrinsic(), getInt32(), llvm::isa(), and llvm::Instruction::setMetadata().
|
inline |
Definition at line 2025 of file IRBuilder.h.
References CreateGEP(), getInt8Ty(), llvm::GEPNoWrapFlags::none(), and llvm::Offset.
Referenced by canonicalizeGEPOfConstGEPI8(), combineConstantOffsets(), constructPointer(), and createByteGEP().
| Value * IRBuilderBase::CreatePtrDiff | ( | 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.
This is intended to implement C-style pointer subtraction. As such, the pointers must be appropriately aligned for their element types and pointing into the same object.
Definition at line 1059 of file IRBuilder.cpp.
References assert(), Context, CreateExactSDiv(), CreatePtrToInt(), CreateSub(), llvm::Type::getInt64Ty(), and llvm::ConstantExpr::getSizeOf().
Definition at line 2162 of file IRBuilder.h.
References BB, and CreateCast().
|
inline |
Definition at line 2166 of file IRBuilder.h.
References CreateCast().
Referenced by llvm::VNCoercion::coerceAvailableValueToLoadType(), convertToShadowDataInt(), CreateBitOrPointerCast(), CreatePtrDiff(), llvm::orc::IRSpeculationLayer::emit(), llvm::memtag::getFP(), llvm::memtag::getPC(), llvm::AMDGPU::instrumentAddress(), and llvm::AMDGPU::instrumentAddressImpl().
|
inline |
Definition at line 1311 of file IRBuilder.h.
References llvm::ResumeInst::Create(), and Insert().
|
inline |
Create a 'ret <val>' instruction.
Definition at line 1175 of file IRBuilder.h.
References Context, llvm::ReturnInst::Create(), and Insert().
Referenced by lowerFunnelShifts(), and lowerIntrinsicToFunction().
|
inline |
Create a 'ret void' instruction.
Definition at line 1170 of file IRBuilder.h.
References Context, llvm::ReturnInst::Create(), and Insert().
Referenced by llvm::lowerGlobalIFuncUsersAsGlobalCtor(), and lowerIntrinsicToFunction().
|
inline |
Definition at line 1470 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by CreateExactSDiv().
| Value * IRBuilderBase::CreateSelect | ( | Value * | C, |
| Value * | True, | ||
| Value * | False, | ||
| const Twine & | Name = "", | ||
| Instruction * | MDFrom = nullptr ) |
Definition at line 1037 of file IRBuilder.cpp.
References llvm::CallingConv::C, and CreateSelectFMF().
Referenced by CreateLogicalAnd(), CreateLogicalOr(), llvm::X86TTIImpl::instCombineIntrinsic(), instCombineSVESel(), and simplifySVEIntrinsicBinOp().
| Value * IRBuilderBase::CreateSelectFMF | ( | Value * | C, |
| Value * | True, | ||
| Value * | False, | ||
| FMFSource | FMFSource, | ||
| const Twine & | Name = "", | ||
| Instruction * | MDFrom = nullptr ) |
Definition at line 1042 of file IRBuilder.cpp.
References llvm::CallingConv::C, llvm::SelectInst::Create(), FMF, Folder, llvm::FMFSource::get(), llvm::Instruction::getMetadata(), Insert(), and llvm::isa().
Referenced by CreateSelect(), CreateSelectFMFWithUnknownProfile(), and CreateSelectWithUnknownProfile().
| Value * IRBuilderBase::CreateSelectFMFWithUnknownProfile | ( | Value * | C, |
| Value * | True, | ||
| Value * | False, | ||
| FMFSource | FMFSource, | ||
| StringRef | PassName, | ||
| const Twine & | Name = "" ) |
Definition at line 1026 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateSelectFMF(), llvm::dyn_cast(), PassName, and llvm::setExplicitlyUnknownBranchWeightsIfProfiled().
| Value * IRBuilderBase::CreateSelectWithUnknownProfile | ( | Value * | C, |
| Value * | True, | ||
| Value * | False, | ||
| StringRef | PassName, | ||
| const Twine & | Name = "" ) |
Definition at line 1015 of file IRBuilder.cpp.
References llvm::CallingConv::C, CreateSelectFMF(), llvm::dyn_cast(), PassName, and llvm::setExplicitlyUnknownBranchWeightsIfProfiled().
Referenced by simplifyShiftSelectingPackedElement().
|
inline |
Definition at line 2066 of file IRBuilder.h.
References CreateCast().
Referenced by CreateSExtOrTrunc(), and llvm::GCNTTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 2194 of file IRBuilder.h.
References CreateCast(), and llvm::Type::getScalarSizeInBits().
|
inline |
Create a SExt or Trunc from the integer value V to DestTy.
Return the value untouched if the type of V is already DestTy.
Definition at line 2087 of file IRBuilder.h.
References assert(), CreateSExt(), CreateTrunc(), llvm::Type::getScalarSizeInBits(), and llvm::Type::isIntOrIntVectorTy().
|
inline |
Definition at line 1504 of file IRBuilder.h.
References CreateShl(), LHS, and RHS.
|
inline |
Definition at line 1510 of file IRBuilder.h.
References CreateShl(), LHS, and RHS.
|
inline |
Definition at line 1495 of file IRBuilder.h.
References Folder, LHS, and RHS.
Referenced by convertToShadowDataInt(), CreateShl(), CreateShl(), getShiftedValue(), llvm::memtag::incrementThreadLong(), llvm::GCNTTIImpl::instCombineIntrinsic(), llvm::X86TTIImpl::instCombineIntrinsic(), lowerFunnelShifts(), and simplifyValueKnownNonZero().
|
inline |
Create a unary shuffle.
The second vector operand of the IR instruction is poison.
Definition at line 2593 of file IRBuilder.h.
References CreateShuffleVector(), and llvm::PoisonValue::get().
|
inline |
See class ShuffleVectorInst for a description of the mask representation.
Definition at line 2584 of file IRBuilder.h.
|
inline |
Definition at line 2576 of file IRBuilder.h.
References llvm::cast(), CreateShuffleVector(), and llvm::ShuffleVectorInst::getShuffleMask().
Referenced by CreateShuffleVector(), CreateShuffleVector(), CreateVectorReverse(), CreateVectorSplat(), CreateVectorSpliceLeft(), CreateVectorSpliceRight(), llvm::X86TTIImpl::instCombineIntrinsic(), instCombineSVEDupqLane(), llvm::GCNTTIImpl::simplifyAMDGCNLaneIntrinsicDemanded(), simplifyAMDGCNMemoryIntrinsicDemanded(), and simplifyNeonTbl().
|
inline |
Definition at line 2127 of file IRBuilder.h.
References CreateCast(), CreateConstrainedFPCast(), and IsFPConstrained.
Create a call to llvm.stackrestore.
Definition at line 1131 of file IRBuilder.h.
References CreateIntrinsic(), and llvm::Value::getType().
Create a call to llvm.stacksave.
Definition at line 1124 of file IRBuilder.h.
References BB, Context, CreateIntrinsic(), and DL.
Creates a vector of type DstType with the linear sequence <0, 1, ...>
Definition at line 147 of file IRBuilder.cpp.
References llvm::cast(), CreateIntrinsic(), CreateTrunc(), llvm::ConstantVector::get(), llvm::VectorType::get(), getInt8Ty(), llvm::Type::getScalarSizeInBits(), llvm::Type::getScalarType(), llvm::isa(), and llvm::SmallVectorTemplateBase< T, bool >::push_back().
|
inline |
Definition at line 1867 of file IRBuilder.h.
References CreateAlignedStore().
Referenced by llvm::orc::IRSpeculationLayer::emit(), instCombineSVEST1(), mergeConditionalStoreToAddress(), and llvm::orc::ReOptimizeLayer::reoptimizeIfCallFrequent().
Create a strip.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 1086 of file IRBuilder.cpp.
References assert(), BB, CreateCall(), llvm::Function::getFunctionType(), llvm::Intrinsic::getOrInsertDeclaration(), llvm::FunctionType::getParamType(), llvm::Function::getReturnType(), llvm::Value::getType(), and llvm::isa().
Referenced by simplifyInvariantGroupIntrinsic().
|
inline |
Definition at line 2018 of file IRBuilder.h.
References CreateConstGEP2_32(), llvm::GEPNoWrapFlags::inBounds(), and llvm::GEPNoWrapFlags::noUnsignedWrap().
|
inline |
Definition at line 1930 of file IRBuilder.h.
References llvm::CallBase::addParamAttr(), llvm::append_range(), CreateIntrinsic(), llvm::Attribute::get(), getContext(), and llvm::Value::getType().
|
inline |
Definition at line 1423 of file IRBuilder.h.
References Folder, LHS, and RHS.
Referenced by createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), CreateNeg(), CreateNSWSub(), CreateNUWSub(), CreatePtrDiff(), foldCtpop(), foldCttzCtlz(), getBoundsCheckCond(), lowerFunnelShifts(), simplifyValueKnownNonZero(), and llvm::UnrollRuntimeLoopRemainder().
|
inline |
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).
Definition at line 1223 of file IRBuilder.h.
References llvm::SwitchInst::Create(), and Insert().
Referenced by foldMemChr().
Create a call to llvm.threadlocal.address intrinsic.
Definition at line 462 of file IRBuilder.cpp.
References A(), llvm::CallBase::addParamAttr(), llvm::CallBase::addRetAttr(), assert(), llvm::cast(), CreateIntrinsic(), llvm::getAlign(), llvm::Value::getContext(), llvm::Value::getType(), llvm::Attribute::getWithAlignment(), and llvm::isa().
|
inline |
Definition at line 2040 of file IRBuilder.h.
References llvm::CastInst::Create(), Folder, I, and Insert().
Referenced by CreateSExtOrTrunc(), CreateStepVector(), CreateZExtOrTrunc(), and foldMemChr().
|
inline |
Definition at line 2202 of file IRBuilder.h.
References CreateCast(), and llvm::Type::getScalarSizeInBits().
Referenced by llvm::VNCoercion::coerceAvailableValueToLoadType().
Create an expression which evaluates to the number of units in Size at runtime.
This works for both units of bits and bytes. This can result in poison if type Ty is not big enough to hold the value.
Definition at line 131 of file IRBuilder.cpp.
References CreateVScaleMultiple(), and Size.
Referenced by CreateAllocationSize(), getBoundsCheckCond(), llvm::AMDGPU::instrumentAddress(), unpackLoadToAggregate(), and unpackStoreToAggregate().
|
inline |
Definition at line 1457 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by CreateExactUDiv(), and getRowFromCol().
|
inline |
Definition at line 2114 of file IRBuilder.h.
References CreateConstrainedFPCast(), Folder, I, Insert(), and IsFPConstrained.
| CallInst * IRBuilderBase::CreateUnaryIntrinsic | ( | Intrinsic::ID | ID, |
| Value * | V, | ||
| FMFSource | FMFSource = {}, | ||
| const Twine & | Name = "" ) |
Create a call to intrinsic ID with 1 operand which is mangled on its type.
Definition at line 837 of file IRBuilder.cpp.
References BB, and llvm::Intrinsic::getOrInsertDeclaration().
Referenced by foldCtpop().
|
inline |
Definition at line 1816 of file IRBuilder.h.
References llvm::UnaryOperator::Create(), FMF, Folder, Insert(), llvm::isa(), and Opc.
Referenced by CreateNAryOp().
|
inline |
Definition at line 1342 of file IRBuilder.h.
References Context, and Insert().
Referenced by createMemMoveLoopUnknownSize(), and expandToSwitch().
|
inline |
Definition at line 1483 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by lowerFunnelShifts().
|
inline |
Definition at line 2538 of file IRBuilder.h.
References Insert(), and llvm::List.
Definition at line 1182 of file IRBuilder.cpp.
References AbstractManglingParser< Derived, Alloc >::Ops, assert(), llvm::cast(), CreateIntrinsic(), llvm::VectorType::get(), llvm::Intrinsic::getInterleaveIntrinsicID(), getType(), I, and llvm::isa().
Return a vector value that contains the vector V reversed.
Definition at line 1103 of file IRBuilder.cpp.
References BB, llvm::cast(), llvm::CallInst::Create(), CreateShuffleVector(), F, llvm::Intrinsic::getOrInsertDeclaration(), Insert(), llvm::isa(), and llvm::SmallVectorTemplateBase< T, bool >::push_back().
| Value * IRBuilderBase::CreateVectorSplat | ( | ElementCount | EC, |
| Value * | V, | ||
| const Twine & | Name = "" ) |
Return a vector value that contains.
EC elements. Definition at line 1168 of file IRBuilder.cpp.
References assert(), CreateInsertElement(), CreateShuffleVector(), llvm::PoisonValue::get(), llvm::VectorType::get(), getInt64(), Poison, and llvm::SmallVectorImpl< T >::resize().
Return a vector value that contains.
NumElts elements. Definition at line 1162 of file IRBuilder.cpp.
References CreateVectorSplat(), and llvm::ElementCount::getFixed().
Referenced by CreateVectorSplat(), llvm::ARMTTIImpl::instCombineIntrinsic(), instCombineSVEDup(), instCombineSVEDupX(), instCombineSVETBL(), instCombineSVEUnpack(), and lowerFunnelShifts().
|
inline |
Definition at line 2677 of file IRBuilder.h.
References CreateVectorSpliceLeft(), getInt32(), and llvm::Offset.
| Value * IRBuilderBase::CreateVectorSpliceLeft | ( | Value * | V1, |
| Value * | V2, | ||
| Value * | Offset, | ||
| const Twine & | Name = "" ) |
Create a vector.splice.left intrinsic call, or a shufflevector that produces the same result if the result type is a fixed-length vector and Offset is a constant.
Definition at line 1127 of file IRBuilder.cpp.
References assert(), CreateIntrinsic(), CreateShuffleVector(), llvm::dyn_cast(), getSpliceMask(), llvm::Value::getType(), llvm::isa(), and llvm::Offset.
Referenced by CreateVectorSpliceLeft().
|
inline |
Definition at line 2688 of file IRBuilder.h.
References CreateVectorSpliceRight(), getInt32(), and llvm::Offset.
| Value * IRBuilderBase::CreateVectorSpliceRight | ( | Value * | V1, |
| Value * | V2, | ||
| Value * | Offset, | ||
| const Twine & | Name = "" ) |
Create a vector.splice.right intrinsic call, or a shufflevector that produces the same result if the result type is a fixed-length vector and Offset is a constant.
Definition at line 1144 of file IRBuilder.cpp.
References assert(), CreateIntrinsic(), CreateShuffleVector(), llvm::dyn_cast(), getSpliceMask(), llvm::Value::getType(), llvm::isa(), and llvm::Offset.
Referenced by CreateVectorSpliceRight().
Create a call to llvm.vscale.<Ty>().
Definition at line 957 of file IRBuilder.h.
References CreateIntrinsic().
|
inline |
Definition at line 1608 of file IRBuilder.h.
References CreateXor(), LHS, and RHS.
|
inline |
Definition at line 1612 of file IRBuilder.h.
References CreateXor(), LHS, and RHS.
Definition at line 1602 of file IRBuilder.h.
References Folder, Insert(), LHS, and RHS.
Referenced by CreateNot(), CreateXor(), CreateXor(), and llvm::memtag::incrementThreadLong().
Create a vector int XOR reduction intrinsic of the source vector.
Definition at line 394 of file IRBuilder.cpp.
|
inline |
Definition at line 2054 of file IRBuilder.h.
References Folder, I, and Insert().
Referenced by CreateZExtOrTrunc(), foldCttzCtlz(), and llvm::GCNTTIImpl::instCombineIntrinsic().
|
inline |
Definition at line 2186 of file IRBuilder.h.
References CreateCast(), and llvm::Type::getScalarSizeInBits().
|
inline |
Create a ZExt or Trunc from the integer value V to DestTy.
Return the value untouched if the type of V is already DestTy.
Definition at line 2072 of file IRBuilder.h.
References assert(), CreateTrunc(), CreateZExt(), llvm::Type::getScalarSizeInBits(), and llvm::Type::isIntOrIntVectorTy().
Referenced by CreateAllocationSize().
|
inline |
Return an all true boolean vector (mask) with NumElts lanes.
Definition at line 861 of file IRBuilder.h.
References Context, llvm::VectorType::get(), llvm::Constant::getAllOnesValue(), and llvm::Type::getInt1Ty().
Referenced by CreateMaskedGather(), and CreateMaskedScatter().
|
inline |
Fetch the type representing a 16-bit brain floating point value.
Definition at line 584 of file IRBuilder.h.
References Context, and llvm::Type::getBFloatTy().
|
inline |
Definition at line 203 of file IRBuilder.h.
References Context.
Referenced by CreateDereferenceableAssumption(), CreateStructuredGEP(), SegmentOffset(), and SetNoSanitizeMetadata().
| DebugLoc IRBuilderBase::getCurrentDebugLocation | ( | ) | const |
Get location information used by debugging information.
Definition at line 64 of file IRBuilder.cpp.
Referenced by llvm::InstrumentationIRBuilder::ensureDebugInfo(), and llvm::IRBuilderBase::InsertPointGuard::InsertPointGuard().
| Type * IRBuilderBase::getCurrentFunctionReturnType | ( | ) | const |
Get the return type of the current function that we're emitting into.
Definition at line 59 of file IRBuilder.cpp.
Referenced by CreateAggregateRet().
|
inline |
Get the exception handling used with constrained floating point.
Definition at line 377 of file IRBuilder.h.
References DefaultConstrainedExcept.
|
inline |
Get the rounding mode handling used with constrained floating point.
Definition at line 382 of file IRBuilder.h.
References DefaultConstrainedRounding.
|
inline |
Get the floating point math metadata being used.
Definition at line 331 of file IRBuilder.h.
References DefaultFPMathTag.
|
inline |
Fetch the type representing a 64-bit floating point value.
Definition at line 594 of file IRBuilder.h.
References Context, and llvm::Type::getDoubleTy().
Referenced by instCombineSVECondLast().
|
inline |
Get the constant value for i1 false.
Definition at line 507 of file IRBuilder.h.
References Context, and llvm::ConstantInt::getFalse().
Referenced by foldCtpop(), and foldCttzCtlz().
|
inline |
Definition at line 336 of file IRBuilder.h.
References FMF.
|
inline |
Get the flags to be applied to created floating point ops.
Definition at line 334 of file IRBuilder.h.
References FMF.
|
inline |
Fetch the type representing a 32-bit floating point value.
Definition at line 589 of file IRBuilder.h.
References Context, and llvm::Type::getFloatTy().
Referenced by instCombineSVECondLast().
|
inline |
Fetch the type representing a 16-bit floating point value.
Definition at line 579 of file IRBuilder.h.
References Context, and llvm::Type::getHalfTy().
Referenced by instCombineSVECondLast().
|
inline |
Fetch the type of an integer that should be used to index GEP operations within AddressSpace.
Definition at line 616 of file IRBuilder.h.
|
inline |
Definition at line 201 of file IRBuilder.h.
References BB.
Referenced by llvm::orc::IRSpeculationLayer::emit(), llvm::memtag::getAndroidSlotPtr(), llvm::memtag::getDarwinSlotPtr(), llvm::TargetLoweringBase::getDefaultSafeStackPointerLocation(), llvm::memtag::getFP(), llvm::RISCVTargetLowering::getIRStackGuard(), llvm::TargetLoweringBase::getIRStackGuard(), llvm::X86TargetLowering::getIRStackGuard(), llvm::memtag::getPC(), llvm::TargetLoweringBase::getSafeStackPointerLocation(), InsertCall(), llvm::IRBuilderBase::InsertPointGuard::InsertPointGuard(), InsertTrap(), llvm::memtag::readRegister(), saveAndClearIP(), saveIP(), llvm::GCNTTIImpl::simplifyAMDGCNLaneIntrinsicDemanded(), UseTlsOffset(), and useTpOffset().
|
inline |
Definition at line 202 of file IRBuilder.h.
References InsertPt.
Referenced by llvm::AMDGPU::genAMDGPUReportBlock(), insertBoundsCheck(), llvm::IRBuilderBase::InsertPointGuard::InsertPointGuard(), mergeConditionalStoreToAddress(), saveAndClearIP(), and saveIP().
|
inline |
Get a constant integer value.
Definition at line 537 of file IRBuilder.h.
References Context.
Referenced by canonicalizeGEPOfConstGEPI8(), combineConstantOffsets(), createByteGEP(), lowerFunnelShifts(), and transformToIndexedCompare().
|
inline |
Get a constant value representing either true or false.
Definition at line 497 of file IRBuilder.h.
References getInt1Ty().
Referenced by CreateCountTrailingZeroElems(), createFFSIntrinsic(), CreateMemSet(), CreateMemSetInline(), and CreateMemTransferInst().
|
inline |
Fetch the type representing a 128-bit integer.
Definition at line 571 of file IRBuilder.h.
References Context, and llvm::Type::getInt128Ty().
|
inline |
Get a constant 16-bit value.
Definition at line 517 of file IRBuilder.h.
References llvm::CallingConv::C, and getInt16Ty().
Referenced by getRowFromCol().
|
inline |
Fetch the type representing a 16-bit integer.
Definition at line 556 of file IRBuilder.h.
References Context, and llvm::Type::getInt16Ty().
Referenced by getInt16().
|
inline |
Fetch the type representing a single bit.
Definition at line 546 of file IRBuilder.h.
References Context, and llvm::Type::getInt1Ty().
Referenced by addBoundsChecking(), CreateAssumption(), getInt1(), and llvm::X86TTIImpl::instCombineIntrinsic().
|
inline |
Get a constant 32-bit value.
Definition at line 522 of file IRBuilder.h.
References llvm::CallingConv::C, and getInt32Ty().
Referenced by appendToGlobalArray(), CreateElementUnorderedAtomicMemCpy(), CreateElementUnorderedAtomicMemMove(), CreateElementUnorderedAtomicMemSet(), CreateGCRelocate(), createIsFPClass(), createOrdering(), CreatePreserveArrayAccessIndex(), CreatePreserveStructAccessIndex(), CreatePreserveUnionAccessIndex(), CreateVectorSpliceLeft(), CreateVectorSpliceRight(), emitDXILVersionTupleMD(), emitShaderModelVersionMD(), emitValidatorVersionMD(), foldVecExtTruncToExtElt(), foldVecTruncToExtElt(), llvm::PPCTTIImpl::instCombineIntrinsic(), nullifySetjmp(), optimizeIntegerToVectorInsertions(), and simplifyAllocaArraySize().
|
inline |
Fetch the type representing a 32-bit integer.
Definition at line 561 of file IRBuilder.h.
References Context, and llvm::Type::getInt32Ty().
Referenced by appendToGlobalArray(), getInt32(), instCombineSVEDupqLane(), and instCombineSVESDIV().
|
inline |
Get a constant 64-bit value.
Definition at line 527 of file IRBuilder.h.
References llvm::CallingConv::C, and getInt64Ty().
Referenced by llvm::VNCoercion::coerceAvailableValueToLoadType(), constructPointer(), CreateElementUnorderedAtomicMemSet(), CreateExtractElement(), CreateExtractVector(), CreateInsertElement(), CreateInsertVector(), CreateInvariantStart(), CreateMemCpy(), CreateMemMove(), CreateMemSet(), CreateVectorSplat(), llvm::GCNTTIImpl::instCombineIntrinsic(), and instCombineSVEDupqLane().
|
inline |
Fetch the type representing a 64-bit integer.
Definition at line 566 of file IRBuilder.h.
References Context, and llvm::Type::getInt64Ty().
Referenced by CreateInvariantStart(), llvm::AMDGPU::genAMDGPUReportBlock(), and getInt64().
|
inline |
Get a constant 8-bit value.
Definition at line 512 of file IRBuilder.h.
References llvm::CallingConv::C, and getInt8Ty().
Referenced by llvm::HexagonTargetLowering::LowerConstantPool().
|
inline |
Fetch the type representing an 8-bit integer.
Definition at line 551 of file IRBuilder.h.
References Context, and llvm::Type::getInt8Ty().
Referenced by CreateGlobalString(), CreateInBoundsPtrAdd(), CreatePtrAdd(), CreateStepVector(), foldMemChr(), llvm::memtag::getAndroidSlotPtr(), llvm::memtag::getDarwinSlotPtr(), getInt8(), InsertTrap(), UseTlsOffset(), and useTpOffset().
|
inline |
Get a constant N-bit value, zero extended from a 64-bit value.
Definition at line 532 of file IRBuilder.h.
References llvm::CallingConv::C, getIntNTy(), and N.
Referenced by getAddrSizeInt().
|
inline |
Fetch the type representing an N-bit integer.
Definition at line 574 of file IRBuilder.h.
References Context, llvm::Type::getIntNTy(), and N.
Referenced by getAddrIntType(), getIntN(), llvm::GCNTTIImpl::instCombineIntrinsic(), and instCombineSVEDupqLane().
|
inline |
Fetch the type of an integer with size at least as big as that of a pointer in the given address space.
Definition at line 610 of file IRBuilder.h.
Referenced by CreateAlignmentAssumption(), llvm::memtag::getFP(), llvm::memtag::getPC(), and llvm::memtag::readRegister().
|
inline |
Query for the use of constrained floating point math.
Definition at line 354 of file IRBuilder.h.
References IsFPConstrained.
|
inline |
Fetch the type representing a pointer.
Definition at line 604 of file IRBuilder.h.
References Context, and llvm::PointerType::get().
Referenced by appendToGlobalArray(), convertToParamAS(), createNVVMInternalAddrspaceWrap(), llvm::memtag::getAndroidSlotPtr(), llvm::memtag::getDarwinSlotPtr(), llvm::memtag::getFP(), handleByValParam(), SegmentOffset(), llvm::UpgradeGlobalVariable(), UseTlsOffset(), and useTpOffset().
|
inline |
Get the constant value for i1 true.
Definition at line 502 of file IRBuilder.h.
References Context, and llvm::ConstantInt::getTrue().
Referenced by foldCttzCtlz(), and llvm::ARMTTIImpl::instCombineIntrinsic().
|
inline |
Fetch the type representing void.
Definition at line 599 of file IRBuilder.h.
References Context, and llvm::Type::getVoidTy().
Referenced by llvm::createSanitizerCtorAndInitFunctions(), and llvm::AMDGPU::generateCrashCode().
No-op overload to handle constants.
Definition at line 179 of file IRBuilder.h.
References llvm::CallingConv::C.
|
inline |
Insert and return the specified instruction.
Definition at line 172 of file IRBuilder.h.
References AddMetadataToInst(), I, Inserter, and InsertPt.
Referenced by CreateAggregateRet(), CreateAlignedLoad(), CreateAlignedStore(), CreateAlloca(), CreateAlloca(), CreateAnd(), CreateAShr(), CreateAtomicCmpXchg(), CreateAtomicRMW(), CreateBinOpFMF(), CreateBr(), CreateCall(), CreateCallBr(), CreateCatchPad(), CreateCatchRet(), CreateCatchSwitch(), CreateCleanupRet(), CreateCondBr(), CreateCondBr(), CreateExtractElement(), CreateExtractValue(), CreateFAddFMF(), CreateFDivFMF(), CreateFence(), CreateFMulFMF(), CreateFNegFMF(), CreateFreeze(), CreateFRemFMF(), CreateFSubFMF(), CreateGEP(), CreateICmp(), CreateIndirectBr(), CreateInsertElement(), CreateInsertValue(), CreateInvoke(), CreateLandingPad(), CreateLShr(), CreateOr(), CreatePHI(), CreatePointerBitCastOrAddrSpaceCast(), CreatePointerCast(), CreateResume(), CreateRet(), CreateRetVoid(), CreateSDiv(), CreateSelectFMF(), CreateShuffleVector(), CreateSRem(), CreateSwitch(), CreateTrunc(), CreateUDiv(), CreateUIToFP(), CreateUnOp(), CreateUnreachable(), CreateURem(), CreateVAArg(), CreateVectorReverse(), CreateXor(), CreateZExt(), Insert(), llvm::Negator::Negate(), and rewriteGlobalVariablesInConstant().
Definition at line 183 of file IRBuilder.h.
References assert(), llvm::dyn_cast(), I, Insert(), and llvm::isa().
|
inline |
Sets the current insert point to a previously-saved location.
Definition at line 323 of file IRBuilder.h.
References ClearInsertionPoint(), llvm::IRBuilderBase::InsertPoint::getBlock(), llvm::IRBuilderBase::InsertPoint::getPoint(), llvm::IRBuilderBase::InsertPoint::isSet(), and SetInsertPoint().
Referenced by emitTargetCall().
|
inline |
Returns the current insert point, clearing it in the process.
Definition at line 316 of file IRBuilder.h.
References ClearInsertionPoint(), GetInsertBlock(), and GetInsertPoint().
|
inline |
Returns the current insert point.
Definition at line 311 of file IRBuilder.h.
References GetInsertBlock(), and GetInsertPoint().
Referenced by emitTargetCall().
|
inline |
Definition at line 395 of file IRBuilder.h.
References I.
Referenced by CreateCall(), CreateConstrainedFPBinOp(), CreateConstrainedFPCall(), CreateConstrainedFPCast(), CreateConstrainedFPCmp(), CreateConstrainedFPIntrinsic(), CreateConstrainedFPUnroundedBinOp(), and CreateInvoke().
|
inline |
Definition at line 386 of file IRBuilder.h.
|
inline |
Set location information used by debugging information.
Definition at line 247 of file IRBuilder.h.
Referenced by buildPartialInvariantUnswitchConditionalBranch(), buildPartialUnswitchConditionalBranch(), CollectMetadataToCopy(), createMemMoveLoopKnownSize(), createMemMoveLoopUnknownSize(), createMemSetLoop(), llvm::InstrumentationIRBuilder::ensureDebugInfo(), llvm::expandMemMoveAsLoop(), foldMemChr(), insertLoopExpansion(), mergeConditionalStoreToAddress(), llvm::Negator::Negate(), SetInsertPoint(), SetInsertPoint(), and SetInsertPoint().
|
inline |
Set the exception handling to be used with constrained floating point.
Definition at line 357 of file IRBuilder.h.
References assert(), llvm::convertExceptionBehaviorToStr(), and DefaultConstrainedExcept.
|
inline |
Set the rounding mode handling to be used with constrained floating point.
Definition at line 367 of file IRBuilder.h.
References assert(), llvm::convertRoundingModeToStr(), and DefaultConstrainedRounding.
|
inline |
Set the floating point math metadata to be used.
Definition at line 342 of file IRBuilder.h.
References DefaultFPMathTag.
|
inline |
Definition at line 399 of file IRBuilder.h.
References DefaultOperandBundles.
|
inline |
Set the fast-math flags to be used with generated fp-math operators.
Definition at line 345 of file IRBuilder.h.
References FMF.
Referenced by createInductionAdditionalBypassValues().
|
inline |
This specifies that created instructions should be appended to the end of the specified block.
Definition at line 207 of file IRBuilder.h.
Referenced by llvm::addDiffRuntimeChecks(), llvm::addRuntimeChecks(), createMemMoveLoopKnownSize(), llvm::createSanitizerCtorAndInitFunctions(), llvm::orc::IRSpeculationLayer::emit(), foldMemChr(), freelyInvert(), llvm::AMDGPU::genAMDGPUReportBlock(), llvm::AMDGPU::generateCrashCode(), llvm::ARMTTIImpl::instCombineIntrinsic(), llvm::AMDGPU::instrumentAddress(), llvm::AMDGPU::instrumentAddressImpl(), llvm::lowerObjectSizeCall(), lowerPtrAnnotation(), mergeConditionalStoreToAddress(), processPhiNode(), processUGT_ADDCST_ADD(), processUMulZExtIdiom(), restoreIP(), simplifyAMDGCNMemoryIntrinsicDemanded(), llvm::X86TTIImpl::simplifyDemandedVectorEltsIntrinsic(), simplifyShiftSelectingPackedElement(), simplifyUsingControlFlow(), simplifyValueKnownNonZero(), llvm::SplitBlockAndInsertForEachLane(), llvm::SplitBlockAndInsertForEachLane(), and llvm::UnrollRuntimeLoopRemainder().
|
inline |
This specifies that created instructions should be inserted at the specified point.
Definition at line 223 of file IRBuilder.h.
References BB, llvm::BasicBlock::end(), InsertPt, and SetCurrentDebugLocation().
|
inline |
This specifies that created instructions should be inserted at the specified point, but also requires that IP is dereferencable.
Definition at line 232 of file IRBuilder.h.
References BB, InsertPt, and SetCurrentDebugLocation().
|
inline |
This specifies that created instructions should be inserted before the specified instruction.
Definition at line 214 of file IRBuilder.h.
References assert(), BB, I, InsertPt, and SetCurrentDebugLocation().
|
inline |
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.
Definition at line 241 of file IRBuilder.h.
| void IRBuilderBase::SetInstDebugLocation | ( | Instruction * | I | ) | const |
If this builder has a current debug location, set it on the specified instruction.
Definition at line 65 of file IRBuilder.cpp.
References I.
Referenced by AddMetadataToInst().
|
inline |
Enable/Disable use of constrained floating point math.
When enabled the CreateF<op>() calls instead create constrained floating point intrinsic calls. Fast math flags are unaffected by this setting.
Definition at line 351 of file IRBuilder.h.
References IsFPConstrained.
|
inline |
Set nosanitize metadata.
Definition at line 254 of file IRBuilder.h.
References llvm::MDNode::get(), and getContext().
Referenced by BuilderTy::BuilderTy().
|
protected |
Definition at line 146 of file IRBuilder.h.
Referenced by ClearInsertionPoint(), CreateAlignedLoad(), CreateAlignedStore(), CreateAlloca(), CreateAlloca(), CreateAllocationSize(), CreateAssumption(), CreateAtomicCmpXchg(), CreateAtomicRMW(), CreateBinaryIntrinsic(), CreateCatchRet(), CreateFree(), CreateGlobalString(), CreateIntrinsic(), CreateIntrinsic(), CreateLaunderInvariantGroup(), CreateMalloc(), CreatePtrToAddr(), CreateStackSave(), CreateStripInvariantGroup(), CreateUnaryIntrinsic(), CreateVectorReverse(), getCurrentFunctionReturnType(), GetInsertBlock(), llvm::InstrumentationIRBuilder::InstrumentationIRBuilder(), setConstrainedFPFunctionAttr(), SetInsertPoint(), SetInsertPoint(), SetInsertPoint(), SetInsertPoint(), and SetInsertPointPastAllocas().
|
protected |
Definition at line 148 of file IRBuilder.h.
Referenced by CreateAggregateRet(), CreateConstGEP1_32(), CreateConstGEP1_64(), CreateConstGEP2_32(), CreateConstGEP2_64(), CreateConstInBoundsGEP1_32(), CreateConstInBoundsGEP1_64(), CreateConstInBoundsGEP2_32(), CreateConstInBoundsGEP2_64(), CreateFence(), CreateGlobalString(), CreateMalloc(), CreateNoAliasScopeDeclaration(), CreatePreserveArrayAccessIndex(), CreatePreserveStructAccessIndex(), CreatePtrDiff(), CreateRet(), CreateRetVoid(), CreateStackSave(), CreateUnreachable(), getAllOnesMask(), getBFloatTy(), getContext(), getDoubleTy(), getFalse(), getFloatTy(), getHalfTy(), getIndexTy(), getInt(), getInt128Ty(), getInt16Ty(), getInt1Ty(), getInt32Ty(), getInt64Ty(), getInt8Ty(), getIntNTy(), getIntPtrTy(), getPtrTy(), getTrue(), getVoidTy(), and IRBuilderBase().
|
protected |
Definition at line 156 of file IRBuilder.h.
Referenced by getDefaultConstrainedExcept(), and setDefaultConstrainedExcept().
|
protected |
Definition at line 157 of file IRBuilder.h.
Referenced by getDefaultConstrainedRounding(), and setDefaultConstrainedRounding().
|
protected |
Definition at line 152 of file IRBuilder.h.
Referenced by llvm::IRBuilderBase::FastMathFlagGuard::FastMathFlagGuard(), getDefaultFPMathTag(), IRBuilderBase(), and setDefaultFPMathTag().
|
protected |
Definition at line 159 of file IRBuilder.h.
Referenced by IRBuilderBase(), and setDefaultOperandBundles().
|
protected |
Definition at line 153 of file IRBuilder.h.
Referenced by clearFastMathFlags(), CreateBinOpFMF(), CreateCall(), CreateConstrainedFPBinOp(), CreateConstrainedFPCast(), CreateConstrainedFPIntrinsic(), CreateConstrainedFPUnroundedBinOp(), CreateFAddFMF(), CreateFDivFMF(), CreateFMulFMF(), CreateFNegFMF(), CreateFRemFMF(), CreateFSubFMF(), CreatePHI(), CreateSelectFMF(), CreateUnOp(), getFastMathFlags(), getFastMathFlags(), and setFastMathFlags().
|
protected |
Definition at line 149 of file IRBuilder.h.
Referenced by CreateAdd(), CreateAnd(), CreateAShr(), CreateBinaryIntrinsic(), CreateBinOpFMF(), CreateExtractElement(), CreateExtractValue(), CreateFAddFMF(), CreateFDivFMF(), CreateFMulFMF(), CreateFNegFMF(), CreateFRemFMF(), CreateFSubFMF(), CreateGEP(), CreateICmp(), CreateInsertElement(), CreateInsertValue(), CreateLShr(), CreateMul(), CreateOr(), CreatePointerBitCastOrAddrSpaceCast(), CreatePointerCast(), CreateSDiv(), CreateSelectFMF(), CreateShl(), CreateShuffleVector(), CreateSRem(), CreateSub(), CreateTrunc(), CreateUDiv(), CreateUIToFP(), CreateUnOp(), CreateURem(), CreateXor(), CreateZExt(), and IRBuilderBase().
|
protected |
Definition at line 150 of file IRBuilder.h.
Referenced by Insert(), and IRBuilderBase().
|
protected |
Definition at line 147 of file IRBuilder.h.
Referenced by ClearInsertionPoint(), GetInsertPoint(), Insert(), SetInsertPoint(), SetInsertPoint(), SetInsertPoint(), SetInsertPoint(), and SetInsertPointPastAllocas().
|
protected |
Definition at line 155 of file IRBuilder.h.
Referenced by CreateCall(), CreateFAddFMF(), CreateFDivFMF(), CreateFMulFMF(), CreateFPExtFMF(), CreateFPToSI(), CreateFPToUI(), CreateFPTruncFMF(), CreateFRemFMF(), CreateFSubFMF(), CreateInvoke(), CreateSIToFP(), CreateUIToFP(), getIsFPConstrained(), and setIsFPConstrained().