LLVM
10.0.0svn
|
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 |
Public Member Functions | |
IRBuilderBase (LLVMContext &context, MDNode *FPMathTag=nullptr, ArrayRef< OperandBundleDef > OpBundles=None) | |
void | ClearInsertionPoint () |
Clear the insertion point: created instructions will not be inserted into a block. More... | |
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. More... | |
void | SetInsertPoint (Instruction *I) |
This specifies that created instructions should be inserted before the specified instruction. More... | |
void | SetInsertPoint (BasicBlock *TheBB, BasicBlock::iterator IP) |
This specifies that created instructions should be inserted at the specified point. More... | |
void | SetCurrentDebugLocation (DebugLoc L) |
Set location information used by debugging information. More... | |
const DebugLoc & | getCurrentDebugLocation () const |
Get location information used by debugging information. More... | |
void | SetInstDebugLocation (Instruction *I) const |
If this builder has a current debug location, set it on the specified instruction. More... | |
Type * | getCurrentFunctionReturnType () const |
Get the return type of the current function that we're emitting into. More... | |
InsertPoint | saveIP () const |
Returns the current insert point. More... | |
InsertPoint | saveAndClearIP () |
Returns the current insert point, clearing it in the process. More... | |
void | restoreIP (InsertPoint IP) |
Sets the current insert point to a previously-saved location. More... | |
MDNode * | getDefaultFPMathTag () const |
Get the floating point math metadata being used. More... | |
FastMathFlags | getFastMathFlags () const |
Get the flags to be applied to created floating point ops. More... | |
void | clearFastMathFlags () |
Clear the fast-math flags. More... | |
void | setDefaultFPMathTag (MDNode *FPMathTag) |
Set the floating point math metadata to be used. More... | |
void | setFastMathFlags (FastMathFlags NewFMF) |
Set the fast-math flags to be used with generated fp-math operators. More... | |
void | setIsFPConstrained (bool IsCon) |
Enable/Disable use of constrained floating point math. More... | |
bool | getIsFPConstrained () |
Query for the use of constrained floating point math. More... | |
void | setDefaultConstrainedExcept (ConstrainedFPIntrinsic::ExceptionBehavior NewExcept) |
Set the exception handling to be used with constrained floating point. More... | |
void | setDefaultConstrainedRounding (ConstrainedFPIntrinsic::RoundingMode NewRounding) |
Set the rounding mode handling to be used with constrained floating point. More... | |
ConstrainedFPIntrinsic::ExceptionBehavior | getDefaultConstrainedExcept () |
Get the exception handling used with constrained floating point. More... | |
ConstrainedFPIntrinsic::RoundingMode | getDefaultConstrainedRounding () |
Get the rounding mode handling used with constrained floating point. More... | |
GlobalVariable * | CreateGlobalString (StringRef Str, const Twine &Name="", unsigned AddressSpace=0) |
Make a new global variable with initializer type i8*. More... | |
ConstantInt * | getInt1 (bool V) |
Get a constant value representing either true or false. More... | |
ConstantInt * | getTrue () |
Get the constant value for i1 true. More... | |
ConstantInt * | getFalse () |
Get the constant value for i1 false. More... | |
ConstantInt * | getInt8 (uint8_t C) |
Get a constant 8-bit value. More... | |
ConstantInt * | getInt16 (uint16_t C) |
Get a constant 16-bit value. More... | |
ConstantInt * | getInt32 (uint32_t C) |
Get a constant 32-bit value. More... | |
ConstantInt * | getInt64 (uint64_t C) |
Get a constant 64-bit value. More... | |
ConstantInt * | getIntN (unsigned N, uint64_t C) |
Get a constant N-bit value, zero extended or truncated from a 64-bit value. More... | |
ConstantInt * | getInt (const APInt &AI) |
Get a constant integer value. More... | |
IntegerType * | getInt1Ty () |
Fetch the type representing a single bit. More... | |
IntegerType * | getInt8Ty () |
Fetch the type representing an 8-bit integer. More... | |
IntegerType * | getInt16Ty () |
Fetch the type representing a 16-bit integer. More... | |
IntegerType * | getInt32Ty () |
Fetch the type representing a 32-bit integer. More... | |
IntegerType * | getInt64Ty () |
Fetch the type representing a 64-bit integer. More... | |
IntegerType * | getInt128Ty () |
Fetch the type representing a 128-bit integer. More... | |
IntegerType * | getIntNTy (unsigned N) |
Fetch the type representing an N-bit integer. More... | |
Type * | getHalfTy () |
Fetch the type representing a 16-bit floating point value. More... | |
Type * | getFloatTy () |
Fetch the type representing a 32-bit floating point value. More... | |
Type * | getDoubleTy () |
Fetch the type representing a 64-bit floating point value. More... | |
Type * | getVoidTy () |
Fetch the type representing void. More... | |
PointerType * | getInt8PtrTy (unsigned AddrSpace=0) |
Fetch the type representing a pointer to an 8-bit integer value. More... | |
IntegerType * | getIntPtrTy (const DataLayout &DL, unsigned AddrSpace=0) |
Fetch the type representing a pointer to an integer value. More... | |
CallInst * | CreateMemSet (Value *Ptr, Value *Val, uint64_t Size, unsigned Align, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
Create and insert a memset to the specified pointer and the specified value. More... | |
CallInst * | CreateMemSet (Value *Ptr, Value *Val, Value *Size, unsigned Align, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
CallInst * | CreateElementUnorderedAtomicMemSet (Value *Ptr, Value *Val, uint64_t Size, unsigned Align, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
Create and insert an element unordered-atomic memset of the region of memory starting at the given pointer to the given value. More... | |
CallInst * | CreateElementUnorderedAtomicMemSet (Value *Ptr, Value *Val, Value *Size, unsigned Align, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
CallInst * | CreateMemCpy (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, uint64_t Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
Create and insert a memcpy between the specified pointers. More... | |
CallInst * | CreateMemCpy (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, Value *Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
CallInst * | CreateElementUnorderedAtomicMemCpy (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, uint64_t Size, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
Create and insert an element unordered-atomic memcpy between the specified pointers. More... | |
CallInst * | CreateElementUnorderedAtomicMemCpy (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, Value *Size, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
CallInst * | CreateMemMove (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, uint64_t Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
Create and insert a memmove between the specified pointers. More... | |
CallInst * | CreateMemMove (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, Value *Size, bool isVolatile=false, MDNode *TBAATag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
CallInst * | CreateElementUnorderedAtomicMemMove (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, uint64_t Size, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
Create and insert an element unordered-atomic memmove between the specified pointers. More... | |
CallInst * | CreateElementUnorderedAtomicMemMove (Value *Dst, unsigned DstAlign, Value *Src, unsigned SrcAlign, Value *Size, uint32_t ElementSize, MDNode *TBAATag=nullptr, MDNode *TBAAStructTag=nullptr, MDNode *ScopeTag=nullptr, MDNode *NoAliasTag=nullptr) |
CallInst * | CreateFAddReduce (Value *Acc, Value *Src) |
Create a vector fadd reduction intrinsic of the source vector. More... | |
CallInst * | CreateFMulReduce (Value *Acc, Value *Src) |
Create a vector fmul reduction intrinsic of the source vector. More... | |
CallInst * | CreateAddReduce (Value *Src) |
Create a vector int add reduction intrinsic of the source vector. More... | |
CallInst * | CreateMulReduce (Value *Src) |
Create a vector int mul reduction intrinsic of the source vector. More... | |
CallInst * | CreateAndReduce (Value *Src) |
Create a vector int AND reduction intrinsic of the source vector. More... | |
CallInst * | CreateOrReduce (Value *Src) |
Create a vector int OR reduction intrinsic of the source vector. More... | |
CallInst * | CreateXorReduce (Value *Src) |
Create a vector int XOR reduction intrinsic of the source vector. More... | |
CallInst * | CreateIntMaxReduce (Value *Src, bool IsSigned=false) |
Create a vector integer max reduction intrinsic of the source vector. More... | |
CallInst * | CreateIntMinReduce (Value *Src, bool IsSigned=false) |
Create a vector integer min reduction intrinsic of the source vector. More... | |
CallInst * | CreateFPMaxReduce (Value *Src, bool NoNaN=false) |
Create a vector float max reduction intrinsic of the source vector. More... | |
CallInst * | CreateFPMinReduce (Value *Src, bool NoNaN=false) |
Create a vector float min reduction intrinsic of the source vector. More... | |
CallInst * | CreateLifetimeStart (Value *Ptr, ConstantInt *Size=nullptr) |
Create a lifetime.start intrinsic. More... | |
CallInst * | CreateLifetimeEnd (Value *Ptr, ConstantInt *Size=nullptr) |
Create a lifetime.end intrinsic. More... | |
CallInst * | CreateInvariantStart (Value *Ptr, ConstantInt *Size=nullptr) |
Create a call to invariant.start intrinsic. More... | |
CallInst * | CreateMaskedLoad (Value *Ptr, unsigned Align, Value *Mask, Value *PassThru=nullptr, const Twine &Name="") |
Create a call to Masked Load intrinsic. More... | |
CallInst * | CreateMaskedStore (Value *Val, Value *Ptr, unsigned Align, Value *Mask) |
Create a call to Masked Store intrinsic. More... | |
CallInst * | CreateMaskedGather (Value *Ptrs, unsigned Align, Value *Mask=nullptr, Value *PassThru=nullptr, const Twine &Name="") |
Create a call to Masked Gather intrinsic. More... | |
CallInst * | CreateMaskedScatter (Value *Val, Value *Ptrs, unsigned Align, Value *Mask=nullptr) |
Create a call to Masked Scatter intrinsic. More... | |
CallInst * | CreateAssumption (Value *Cond) |
Create an assume intrinsic call that allows the optimizer to assume that the provided condition will be true. More... | |
CallInst * | CreateGCStatepointCall (uint64_t ID, uint32_t NumPatchBytes, Value *ActualCallee, ArrayRef< Value *> CallArgs, ArrayRef< Value *> DeoptArgs, ArrayRef< Value *> GCArgs, const Twine &Name="") |
Create a call to the experimental.gc.statepoint intrinsic to start a new statepoint sequence. More... | |
CallInst * | CreateGCStatepointCall (uint64_t ID, uint32_t NumPatchBytes, Value *ActualCallee, uint32_t Flags, ArrayRef< Use > CallArgs, ArrayRef< Use > TransitionArgs, ArrayRef< Use > DeoptArgs, ArrayRef< Value *> GCArgs, const Twine &Name="") |
Create a call to the experimental.gc.statepoint intrinsic to start a new statepoint sequence. More... | |
CallInst * | CreateGCStatepointCall (uint64_t ID, uint32_t NumPatchBytes, Value *ActualCallee, ArrayRef< Use > CallArgs, ArrayRef< Value *> DeoptArgs, ArrayRef< Value *> GCArgs, const Twine &Name="") |
Conveninence function for the common case when CallArgs are filled in using makeArrayRef(CS.arg_begin(), CS.arg_end()); Use needs to be .get()'ed to get the Value pointer. More... | |
InvokeInst * | CreateGCStatepointInvoke (uint64_t ID, uint32_t NumPatchBytes, Value *ActualInvokee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Value *> InvokeArgs, ArrayRef< Value *> DeoptArgs, ArrayRef< Value *> GCArgs, const Twine &Name="") |
Create an invoke to the experimental.gc.statepoint intrinsic to start a new statepoint sequence. More... | |
InvokeInst * | CreateGCStatepointInvoke (uint64_t ID, uint32_t NumPatchBytes, Value *ActualInvokee, BasicBlock *NormalDest, BasicBlock *UnwindDest, uint32_t Flags, ArrayRef< Use > InvokeArgs, ArrayRef< Use > TransitionArgs, ArrayRef< Use > DeoptArgs, ArrayRef< Value *> GCArgs, const Twine &Name="") |
Create an invoke to the experimental.gc.statepoint intrinsic to start a new statepoint sequence. More... | |
InvokeInst * | CreateGCStatepointInvoke (uint64_t ID, uint32_t NumPatchBytes, Value *ActualInvokee, BasicBlock *NormalDest, BasicBlock *UnwindDest, ArrayRef< Use > InvokeArgs, ArrayRef< Value *> DeoptArgs, ArrayRef< Value *> GCArgs, const Twine &Name="") |
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. More... | |
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. More... | |
CallInst * | CreateUnaryIntrinsic (Intrinsic::ID ID, Value *V, Instruction *FMFSource=nullptr, const Twine &Name="") |
Create a call to intrinsic ID with 1 operand which is mangled on its type. More... | |
CallInst * | CreateBinaryIntrinsic (Intrinsic::ID ID, Value *LHS, Value *RHS, Instruction *FMFSource=nullptr, const Twine &Name="") |
Create a call to intrinsic ID with 2 operands which is mangled on the first type. More... | |
CallInst * | CreateIntrinsic (Intrinsic::ID ID, ArrayRef< Type *> Types, ArrayRef< Value *> Args, Instruction *FMFSource=nullptr, const Twine &Name="") |
Create a call to intrinsic ID with args , mangled using Types . More... | |
CallInst * | CreateMinNum (Value *LHS, Value *RHS, const Twine &Name="") |
Create call to the minnum intrinsic. More... | |
CallInst * | CreateMaxNum (Value *LHS, Value *RHS, const Twine &Name="") |
Create call to the maxnum intrinsic. More... | |
CallInst * | CreateMinimum (Value *LHS, Value *RHS, const Twine &Name="") |
Create call to the minimum intrinsic. More... | |
CallInst * | CreateMaximum (Value *LHS, Value *RHS, const Twine &Name="") |
Create call to the maximum intrinsic. More... | |
Common base class shared among various IRBuilders.
Definition at line 88 of file IRBuilder.h.
|
inline |
Definition at line 106 of file IRBuilder.h.
|
inline |
Clear the fast-math flags.
Definition at line 219 of file IRBuilder.h.
References llvm::FastMathFlags::clear().
|
inline |
Clear the insertion point: created instructions will not be inserted into a block.
Definition at line 121 of file IRBuilder.h.
Referenced by llvm::SCEVExpander::clearInsertPoint().
Create a vector int add reduction intrinsic of the source vector.
Definition at line 341 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
Create a vector int AND reduction intrinsic of the source vector.
Definition at line 351 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
Create an assume intrinsic call that allows the optimizer to assume that the provided condition will be true.
Definition at line 452 of file IRBuilder.cpp.
CallInst * IRBuilderBase::CreateBinaryIntrinsic | ( | Intrinsic::ID | ID, |
Value * | LHS, | ||
Value * | RHS, | ||
Instruction * | FMFSource = nullptr , |
||
const Twine & | Name = "" |
||
) |
Create a call to intrinsic ID
with 2 operands which is mangled on the first type.
Definition at line 741 of file IRBuilder.cpp.
References BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), llvm::BasicBlock::getModule(), llvm::Value::getType(), and Name.
Referenced by canonicalizeSaturatedAdd(), canonicalizeSaturatedSubtract(), generatePoisonChecksForBinOp(), and OptimizeNoopCopyExpression().
|
inline |
Create and insert an element unordered-atomic memcpy between the specified pointers.
DstAlign/SrcAlign are the alignments of the Dst/Src pointers, respectively.
If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.
Definition at line 508 of file IRBuilder.h.
CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemCpy | ( | Value * | Dst, |
unsigned | DstAlign, | ||
Value * | Src, | ||
unsigned | SrcAlign, | ||
Value * | Size, | ||
uint32_t | ElementSize, | ||
MDNode * | TBAATag = nullptr , |
||
MDNode * | TBAAStructTag = nullptr , |
||
MDNode * | ScopeTag = nullptr , |
||
MDNode * | NoAliasTag = nullptr |
||
) |
Definition at line 196 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), CreateMemMove(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), llvm::Instruction::setMetadata(), and Size.
|
inline |
Create and insert an element unordered-atomic memmove between the specified pointers.
DstAlign/SrcAlign are the alignments of the Dst/Src pointers, respectively.
If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.
Definition at line 552 of file IRBuilder.h.
References llvm::BitmaskEnumDetail::Mask(), and Name.
CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemMove | ( | Value * | Dst, |
unsigned | DstAlign, | ||
Value * | Src, | ||
unsigned | SrcAlign, | ||
Value * | Size, | ||
uint32_t | ElementSize, | ||
MDNode * | TBAATag = nullptr , |
||
MDNode * | TBAAStructTag = nullptr , |
||
MDNode * | ScopeTag = nullptr , |
||
MDNode * | NoAliasTag = nullptr |
||
) |
Definition at line 272 of file IRBuilder.cpp.
References llvm::CallBase::addParamAttr(), llvm::AMDGPU::HSAMD::Kernel::Arg::Key::Align, assert(), BB, createCallHelper(), llvm::Value::getContext(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), llvm::Attribute::getWithAlignment(), llvm::Instruction::setMetadata(), 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 a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.
Definition at line 459 of file IRBuilder.h.
CallInst * IRBuilderBase::CreateElementUnorderedAtomicMemSet | ( | Value * | Ptr, |
Value * | Val, | ||
Value * | Size, | ||
unsigned | Align, | ||
uint32_t | ElementSize, | ||
MDNode * | TBAATag = nullptr , |
||
MDNode * | ScopeTag = nullptr , |
||
MDNode * | NoAliasTag = nullptr |
||
) |
Definition at line 127 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), CreateMemCpy(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), llvm::Instruction::setMetadata(), and Size.
Create a vector fadd reduction intrinsic of the source vector.
The first parameter is a scalar accumulator value for ordered reductions.
Definition at line 323 of file IRBuilder.cpp.
References createCallHelper(), llvm::Intrinsic::getDeclaration(), GetInsertBlock(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), and llvm::Value::getType().
Referenced by llvm::createSimpleTargetReduction().
Create a vector fmul reduction intrinsic of the source vector.
The first parameter is a scalar accumulator value for ordered reductions.
Definition at line 332 of file IRBuilder.cpp.
References createCallHelper(), llvm::Intrinsic::getDeclaration(), GetInsertBlock(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), and llvm::Value::getType().
Referenced by llvm::createSimpleTargetReduction().
Create a vector float max reduction intrinsic of the source vector.
Definition at line 378 of file IRBuilder.cpp.
References FMF, getReductionIntrinsic(), and llvm::FastMathFlags::setNoNaNs().
Referenced by llvm::createSimpleTargetReduction().
Create a vector float min reduction intrinsic of the source vector.
Definition at line 389 of file IRBuilder.cpp.
References FMF, getReductionIntrinsic(), and llvm::FastMathFlags::setNoNaNs().
Referenced by llvm::createSimpleTargetReduction().
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 717 of file IRBuilder.cpp.
References llvm::AMDGPU::HSAMD::Kernel::Key::Args, BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::BasicBlock::getParent(), and llvm::GlobalValue::getParent().
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 705 of file IRBuilder.cpp.
References llvm::AMDGPU::HSAMD::Kernel::Key::Args, BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), llvm::BasicBlock::getParent(), and llvm::GlobalValue::getParent().
CallInst * IRBuilderBase::CreateGCStatepointCall | ( | uint64_t | ID, |
uint32_t | NumPatchBytes, | ||
Value * | ActualCallee, | ||
ArrayRef< Value *> | CallArgs, | ||
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 624 of file IRBuilder.cpp.
References Name, and llvm::None.
CallInst * IRBuilderBase::CreateGCStatepointCall | ( | uint64_t | ID, |
uint32_t | NumPatchBytes, | ||
Value * | ActualCallee, | ||
uint32_t | Flags, | ||
ArrayRef< Use > | CallArgs, | ||
ArrayRef< Use > | TransitionArgs, | ||
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 633 of file IRBuilder.cpp.
References Name.
CallInst * IRBuilderBase::CreateGCStatepointCall | ( | uint64_t | ID, |
uint32_t | NumPatchBytes, | ||
Value * | ActualCallee, | ||
ArrayRef< Use > | CallArgs, | ||
ArrayRef< Value *> | DeoptArgs, | ||
ArrayRef< Value *> | GCArgs, | ||
const Twine & | Name = "" |
||
) |
Conveninence function for the common case when CallArgs are filled in using makeArrayRef(CS.arg_begin(), CS.arg_end()); Use needs to be .get()'ed to get the Value pointer.
Definition at line 642 of file IRBuilder.cpp.
References Name, and llvm::None.
InvokeInst * IRBuilderBase::CreateGCStatepointInvoke | ( | uint64_t | ID, |
uint32_t | NumPatchBytes, | ||
Value * | ActualInvokee, | ||
BasicBlock * | NormalDest, | ||
BasicBlock * | UnwindDest, | ||
ArrayRef< Value *> | InvokeArgs, | ||
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 674 of file IRBuilder.cpp.
References Name, and llvm::None.
InvokeInst * IRBuilderBase::CreateGCStatepointInvoke | ( | uint64_t | ID, |
uint32_t | NumPatchBytes, | ||
Value * | ActualInvokee, | ||
BasicBlock * | NormalDest, | ||
BasicBlock * | UnwindDest, | ||
uint32_t | Flags, | ||
ArrayRef< Use > | InvokeArgs, | ||
ArrayRef< Use > | TransitionArgs, | ||
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 685 of file IRBuilder.cpp.
References Name.
InvokeInst * IRBuilderBase::CreateGCStatepointInvoke | ( | uint64_t | ID, |
uint32_t | NumPatchBytes, | ||
Value * | ActualInvokee, | ||
BasicBlock * | NormalDest, | ||
BasicBlock * | UnwindDest, | ||
ArrayRef< Use > | InvokeArgs, | ||
ArrayRef< Value *> | DeoptArgs, | ||
ArrayRef< Value *> | GCArgs, | ||
const Twine & | Name = "" |
||
) |
Definition at line 695 of file IRBuilder.cpp.
References Name, and llvm::None.
GlobalVariable * IRBuilderBase::CreateGlobalString | ( | StringRef | Str, |
const Twine & | Name = "" , |
||
unsigned | AddressSpace = 0 |
||
) |
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 Name is specified, it is the name of the global variable created.
Definition at line 42 of file IRBuilder.cpp.
References BB, Context, llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::ConstantDataArray::getString(), llvm::Value::getType(), llvm::GlobalValue::Global, Name, llvm::Align::None(), llvm::GlobalValue::NotThreadLocal, llvm::GlobalValue::PrivateLinkage, and llvm::GlobalValue::setUnnamedAddr().
Referenced by isReportingError().
Create a vector integer max reduction intrinsic of the source vector.
Definition at line 366 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
Create a vector integer min reduction intrinsic of the source vector.
Definition at line 372 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
CallInst * IRBuilderBase::CreateIntrinsic | ( | Intrinsic::ID | ID, |
ArrayRef< Type *> | Types, | ||
ArrayRef< Value *> | Args, | ||
Instruction * | FMFSource = nullptr , |
||
const Twine & | Name = "" |
||
) |
Create a call to intrinsic ID
with args
, mangled using Types
.
If FMFSource
is provided, copy fast-math-flags from that instruction to the intrinsic.
Definition at line 750 of file IRBuilder.cpp.
References BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), and llvm::BasicBlock::getModule().
Referenced by getMulHu(), and simplifyX86addcarry().
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 432 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt64(), getInt64Ty(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::ConstantInt::getType(), llvm::Value::getType(), and Size.
CallInst * IRBuilderBase::CreateLifetimeEnd | ( | Value * | Ptr, |
ConstantInt * | Size = nullptr |
||
) |
Create a lifetime.end intrinsic.
If the pointer isn't i8* it will be converted.
Definition at line 416 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt64(), getInt64Ty(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::ConstantInt::getType(), llvm::Value::getType(), and Size.
Referenced by GetRMWLibcall().
CallInst * IRBuilderBase::CreateLifetimeStart | ( | Value * | Ptr, |
ConstantInt * | Size = nullptr |
||
) |
Create a lifetime.start intrinsic.
If the pointer isn't i8* it will be converted.
Definition at line 400 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt64(), getInt64Ty(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::ConstantInt::getType(), llvm::Value::getType(), and Size.
Referenced by GetRMWLibcall().
CallInst * IRBuilderBase::CreateMaskedGather | ( | Value * | Ptrs, |
unsigned | Align, | ||
Value * | Mask = nullptr , |
||
Value * | PassThru = nullptr , |
||
const Twine & | Name = "" |
||
) |
Create a call to Masked Gather intrinsic.
Create a call to a Masked Gather intrinsic.
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 522 of file IRBuilder.cpp.
References Context, llvm::VectorType::get(), llvm::UndefValue::get(), llvm::Constant::getAllOnesValue(), llvm::Type::getInt1Ty(), getInt32(), llvm::Value::getType(), and llvm::BitmaskEnumDetail::Mask().
Referenced by llvm::InnerLoopVectorizer::vectorizeMemoryInstruction().
CallInst * IRBuilderBase::CreateMaskedLoad | ( | Value * | Ptr, |
unsigned | Align, | ||
Value * | Mask, | ||
Value * | PassThru = nullptr , |
||
const Twine & | Name = "" |
||
) |
Create a call to Masked Load intrinsic.
Create a call to a Masked Load intrinsic.
Ptr
- base pointer for the load Align
- 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 470 of file IRBuilder.cpp.
References assert(), llvm::UndefValue::get(), getInt32(), llvm::Value::getType(), and llvm::BitmaskEnumDetail::Mask().
Referenced by simplifyX86MaskedLoad(), UpgradeMaskedLoad(), llvm::InnerLoopVectorizer::vectorizeInterleaveGroup(), and llvm::InnerLoopVectorizer::vectorizeMemoryInstruction().
CallInst * IRBuilderBase::CreateMaskedScatter | ( | Value * | Data, |
Value * | Ptrs, | ||
unsigned | Align, | ||
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 553 of file IRBuilder.cpp.
References assert(), Context, llvm::Data, llvm::VectorType::get(), llvm::Constant::getAllOnesValue(), llvm::Type::getInt1Ty(), getInt32(), and llvm::Value::getType().
Referenced by llvm::InnerLoopVectorizer::vectorizeMemoryInstruction().
CallInst * IRBuilderBase::CreateMaskedStore | ( | Value * | Val, |
Value * | Ptr, | ||
unsigned | Align, | ||
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 Align
- alignment of the destination location Mask
- vector of booleans which indicates what vector lanes should be accessed in memory
Definition at line 491 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt32(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), and Name.
Referenced by simplifyX86MaskedStore(), UpgradeMaskedStore(), llvm::InnerLoopVectorizer::vectorizeInterleaveGroup(), and llvm::InnerLoopVectorizer::vectorizeMemoryInstruction().
|
inline |
Create call to the maximum intrinsic.
Definition at line 750 of file IRBuilder.h.
References llvm::maximum(), and Name.
|
inline |
Create call to the maxnum intrinsic.
Definition at line 740 of file IRBuilder.h.
References llvm::maxnum(), and Name.
|
inline |
Create and insert a memcpy between the specified pointers.
If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.
Definition at line 482 of file IRBuilder.h.
References isVolatile().
Referenced by annotateNonNullAndDereferenceable(), CreateElementUnorderedAtomicMemSet(), handleMemIntrinsicPtrUse(), isCallPromotable(), isReportingError(), llvm::LibCallSimplifier::LibCallSimplifier(), moveUp(), optimizeMemCmpConstantSize(), and StackMallocSizeClass().
CallInst * IRBuilderBase::CreateMemCpy | ( | Value * | Dst, |
unsigned | DstAlign, | ||
Value * | Src, | ||
unsigned | SrcAlign, | ||
Value * | Size, | ||
bool | isVolatile = false , |
||
MDNode * | TBAATag = nullptr , |
||
MDNode * | TBAAStructTag = nullptr , |
||
MDNode * | ScopeTag = nullptr , |
||
MDNode * | NoAliasTag = nullptr |
||
) |
Definition at line 158 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt1(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), llvm::isPowerOf2_32(), llvm::Instruction::setMetadata(), and Size.
|
inline |
Create and insert a memmove between the specified pointers.
If the pointers aren't i8*, they will be converted. If a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.
Definition at line 530 of file IRBuilder.h.
References isVolatile().
Referenced by CreateElementUnorderedAtomicMemCpy(), handleMemIntrinsicPtrUse(), isCallPromotable(), isReportingError(), llvm::LibCallSimplifier::LibCallSimplifier(), moveUp(), and optimizeMemCmpConstantSize().
CallInst * IRBuilderBase::CreateMemMove | ( | Value * | Dst, |
unsigned | DstAlign, | ||
Value * | Src, | ||
unsigned | SrcAlign, | ||
Value * | Size, | ||
bool | isVolatile = false , |
||
MDNode * | TBAATag = nullptr , |
||
MDNode * | ScopeTag = nullptr , |
||
MDNode * | NoAliasTag = nullptr |
||
) |
Definition at line 238 of file IRBuilder.cpp.
References assert(), BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt1(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), llvm::isPowerOf2_32(), llvm::Instruction::setMetadata(), 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 a TBAA tag is specified, it will be added to the instruction. Likewise with alias.scope and noalias tags.
Definition at line 440 of file IRBuilder.h.
References isVolatile(), and Size.
Referenced by annotateNonNullAndDereferenceable(), createInvokeHelper(), getAllocaSizeInBytes(), handleMemIntrinsicPtrUse(), hasUndefContents(), isCallPromotable(), llvm::LibCallSimplifier::LibCallSimplifier(), moveUp(), and optimizeMemCmpConstantSize().
CallInst * IRBuilderBase::CreateMemSet | ( | Value * | Ptr, |
Value * | Val, | ||
Value * | Size, | ||
unsigned | Align, | ||
bool | isVolatile = false , |
||
MDNode * | TBAATag = nullptr , |
||
MDNode * | ScopeTag = nullptr , |
||
MDNode * | NoAliasTag = nullptr |
||
) |
Definition at line 100 of file IRBuilder.cpp.
References BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), getInt1(), llvm::BasicBlock::getParent(), llvm::GlobalValue::getParent(), llvm::Value::getType(), llvm::Instruction::setMetadata(), and Size.
|
inline |
Create call to the minimum intrinsic.
Definition at line 745 of file IRBuilder.h.
References llvm::minimum(), and Name.
|
inline |
Create call to the minnum intrinsic.
Definition at line 735 of file IRBuilder.h.
References llvm::minnum(), and Name.
Create a vector int mul reduction intrinsic of the source vector.
Definition at line 346 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
Create a vector int OR reduction intrinsic of the source vector.
Definition at line 356 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
CallInst * IRBuilderBase::CreateUnaryIntrinsic | ( | Intrinsic::ID | ID, |
Value * | V, | ||
Instruction * | FMFSource = nullptr , |
||
const Twine & | Name = "" |
||
) |
Create a call to intrinsic ID
with 1 operand which is mangled on its type.
Definition at line 733 of file IRBuilder.cpp.
References BB, createCallHelper(), llvm::Intrinsic::getDeclaration(), llvm::BasicBlock::getModule(), llvm::Value::getType(), and Name.
Referenced by getMulHu().
Create a vector int XOR reduction intrinsic of the source vector.
Definition at line 361 of file IRBuilder.cpp.
References getReductionIntrinsic().
Referenced by llvm::createSimpleTargetReduction().
|
inline |
Definition at line 128 of file IRBuilder.h.
References Context.
Referenced by createOrdering(), emitBinaryFloatFnCallHelper(), emitUnaryFloatFnCallHelper(), performMaskedAtomicOp(), and SegmentOffset().
Get location information used by debugging information.
Definition at line 159 of file IRBuilder.h.
Referenced by llvm::SCEVExpander::getCurrentDebugLocation().
Type * IRBuilderBase::getCurrentFunctionReturnType | ( | ) | const |
Get the return type of the current function that we're emitting into.
Definition at line 56 of file IRBuilder.cpp.
References assert(), BB, llvm::BasicBlock::getInstList(), getInt8PtrTy(), llvm::BasicBlock::getParent(), llvm::Function::getReturnType(), llvm::Value::getType(), llvm::iplist_impl< IntrusiveListT, TraitsT >::insert(), InsertPt, and SetInstDebugLocation().
|
inline |
Get the exception handling used with constrained floating point.
Definition at line 249 of file IRBuilder.h.
|
inline |
Get the rounding mode handling used with constrained floating point.
Definition at line 254 of file IRBuilder.h.
|
inline |
Get the floating point math metadata being used.
Definition at line 213 of file IRBuilder.h.
|
inline |
Fetch the type representing a 64-bit floating point value.
Definition at line 411 of file IRBuilder.h.
References llvm::Type::getDoubleTy().
Referenced by optimizeDoubleFP().
|
inline |
Get the constant value for i1 false.
Definition at line 328 of file IRBuilder.h.
References llvm::ConstantInt::getFalse().
Referenced by buildOrChain(), createFFSIntrinsic(), llvm::InnerLoopVectorizer::emitMinimumIterationCountCheck(), handleNoSuspendCoroutine(), and llvm::LoopPredicationPass::run().
|
inline |
Get the flags to be applied to created floating point ops.
Definition at line 216 of file IRBuilder.h.
Referenced by getMulHu().
|
inline |
Fetch the type representing a 32-bit floating point value.
Definition at line 406 of file IRBuilder.h.
References llvm::Type::getFloatTy().
Referenced by getMulHu(), and optimizeDoubleFP().
|
inline |
Fetch the type representing a 16-bit floating point value.
Definition at line 401 of file IRBuilder.h.
References llvm::Type::getHalfTy().
|
inline |
Definition at line 126 of file IRBuilder.h.
Referenced by callIntrinsic(), llvm::SanitizerStatReport::create(), createCallHelper(), CreateFAddReduce(), createFFSIntrinsic(), CreateFMulReduce(), CreateGCStatepointCallCommon(), CreateGCStatepointInvokeCommon(), createInvokeHelper(), createPopcntIntrinsic(), llvm::orc::IRSpeculationLayer::emit(), llvm::AArch64TargetLowering::emitAtomicCmpXchgNoStoreLLBalance(), llvm::ARMTargetLowering::emitAtomicCmpXchgNoStoreLLBalance(), llvm::emitBCmp(), emitBinaryFloatFnCallHelper(), llvm::emitCalloc(), llvm::emitFGetCUnlocked(), llvm::emitFGetSUnlocked(), llvm::emitFPutC(), llvm::emitFPutCUnlocked(), llvm::emitFPutS(), llvm::emitFPutSUnlocked(), llvm::emitFReadUnlocked(), llvm::emitFWrite(), llvm::emitFWriteUnlocked(), emitLibCall(), llvm::HexagonTargetLowering::emitLoadLinked(), llvm::AArch64TargetLowering::emitLoadLinked(), llvm::ARMTargetLowering::emitLoadLinked(), llvm::emitMalloc(), llvm::emitMemChr(), llvm::emitMemCmp(), llvm::emitMemCpyChk(), llvm::emitPutChar(), llvm::emitPutS(), llvm::HexagonTargetLowering::emitStoreConditional(), llvm::AArch64TargetLowering::emitStoreConditional(), llvm::ARMTargetLowering::emitStoreConditional(), llvm::emitStrLen(), llvm::emitStrNCmp(), llvm::PPCTargetLowering::emitTrailingFence(), emitUnaryFloatFnCallHelper(), generateUnsignedDivisionCode(), llvm::TargetLoweringBase::getDefaultSafeStackPointerLocation(), llvm::TargetLoweringBase::getIRStackGuard(), getReductionIntrinsic(), llvm::TargetLoweringBase::getSafeStackPointerLocation(), insertSinCosCall(), isKnownTypeIdMember(), isReportingError(), llvm::ARMTargetLowering::makeDMB(), optimizeMemCmpConstantSize(), performMaskedAtomicOp(), RetagMask(), llvm::HWAddressSanitizerPass::run(), TypeSizeToSizeIndex(), and UseTlsOffset().
|
inline |
Definition at line 127 of file IRBuilder.h.
Referenced by createCallHelper(), createInvokeHelper(), llvm::InnerLoopVectorizer::emitTransformedIndex(), llvm::expandDivision(), llvm::expandRemainder(), insertBoundsCheck(), instrumentOneFunc(), llvm::log2(), performMaskedAtomicOp(), postDominates(), and TypeSizeToSizeIndex().
|
inline |
Get a constant integer value.
Definition at line 359 of file IRBuilder.h.
References llvm::ConstantInt::get().
Referenced by annotateNonNullAndDereferenceable().
|
inline |
Get a constant value representing either true or false.
Definition at line 318 of file IRBuilder.h.
References llvm::ConstantInt::get().
Referenced by llvm::createBitMaskForGaps(), CreateMemCpy(), CreateMemMove(), and CreateMemSet().
|
inline |
Fetch the type representing a 128-bit integer.
Definition at line 393 of file IRBuilder.h.
References llvm::Type::getInt128Ty().
|
inline |
Get a constant 16-bit value.
Definition at line 338 of file IRBuilder.h.
References llvm::ConstantInt::get().
|
inline |
Fetch the type representing a 16-bit integer.
Definition at line 378 of file IRBuilder.h.
References llvm::Type::getInt16Ty().
Referenced by llvm::ModuleSanitizerCoveragePass::run().
|
inline |
Fetch the type representing a single bit.
Definition at line 368 of file IRBuilder.h.
References llvm::Type::getInt1Ty().
Referenced by EmitX86ScalarSelect(), getX86MaskVec(), and upgradeMaskedCompare().
|
inline |
Get a constant 32-bit value.
Definition at line 343 of file IRBuilder.h.
References llvm::ConstantInt::get().
Referenced by canonicalizeInsertSplat(), CreateElementUnorderedAtomicMemCpy(), CreateElementUnorderedAtomicMemMove(), CreateElementUnorderedAtomicMemSet(), CreateGCRelocate(), CreateGCRelocates(), llvm::createInterleaveMask(), CreateMaskedGather(), CreateMaskedLoad(), CreateMaskedScatter(), CreateMaskedStore(), createOrdering(), createRdxShuffleMask(), llvm::createReplicatedMask(), llvm::HexagonTargetLowering::emitStoreConditional(), llvm::VPBranchOnMaskRecipe::execute(), llvm::VPBasicBlock::execute(), llvm::InnerLoopVectorizer::fixFirstOrderRecurrence(), llvm::InnerLoopVectorizer::fixReduction(), foldVecTruncToExtElt(), generateSignedDivisionCode(), generateSignedRemainderCode(), generateUnsignedDivisionCode(), getMulHu(), llvm::InnerLoopVectorizer::getOrCreateScalarValue(), llvm::getOrderedReduction(), getOrInsertGlobal(), getScalarIntrinsicDeclaration(), llvm::getShuffleReduction(), getSignature(), getStatepointArgs(), getSuccState(), INITIALIZE_PASS(), instrumentMaskedLoadOrStore(), instrumentOneFunc(), isIndirectBrTarget(), isReportingError(), llvm::ARMTargetLowering::lowerInterleavedLoad(), llvm::ARMTargetLowering::lowerInterleavedStore(), llvm::ARMTargetLowering::makeDMB(), optimizeIntegerToVectorInsertions(), llvm::InnerLoopVectorizer::packScalarIntoVectorValue(), llvm::InnerLoopVectorizer::reverseVector(), shouldKeepInEntry(), simplifyAllocaArraySize(), TypeSizeToSizeIndex(), llvm::InnerLoopVectorizer::vectorizeInterleaveGroup(), and llvm::InnerLoopVectorizer::vectorizeMemoryInstruction().
|
inline |
Fetch the type representing a 32-bit integer.
Definition at line 383 of file IRBuilder.h.
References llvm::Type::getInt32Ty().
Referenced by llvm::SanitizerStatReport::create(), createOrdering(), createPowWithIntegerExponent(), createPrivateNonConstGlobalForString(), createRdxShuffleMask(), llvm::emitBCmp(), llvm::emitFGetCUnlocked(), llvm::emitFGetSUnlocked(), llvm::emitFPutC(), llvm::emitFPutCUnlocked(), llvm::emitFPutS(), llvm::emitFPutSUnlocked(), llvm::emitMemCCpy(), llvm::emitMemChr(), llvm::emitMemCmp(), llvm::emitPutChar(), llvm::emitPutS(), llvm::emitSNPrintf(), llvm::emitSPrintf(), llvm::emitStrChr(), llvm::emitStrNCmp(), llvm::emitVSNPrintf(), llvm::emitVSPrintf(), llvm::expandDivisionUpTo32Bits(), llvm::expandRemainderUpTo32Bits(), getGlobalVariableI32(), getIntrinsicForMaskedAtomicRMWBinOp(), getIntToFPVal(), getMul64(), getMulHu(), getOrInsertGlobal(), llvm::getShuffleReduction(), getSignature(), getSuccState(), GlobalWasGeneratedByCompiler(), insertSinCosCall(), insertValues(), instrumentMaskedLoadOrStore(), isAtomic(), llvm::log2(), RetagMask(), llvm::HWAddressSanitizerPass::run(), llvm::ModuleSanitizerCoveragePass::run(), shouldKeepInEntry(), and TypeSizeToSizeIndex().
|
inline |
Get a constant 64-bit value.
Definition at line 348 of file IRBuilder.h.
References llvm::ConstantInt::get().
Referenced by annotateNonNullAndDereferenceable(), CreateInvariantStart(), CreateLifetimeEnd(), CreateLifetimeStart(), generateSignedDivisionCode(), generateSignedRemainderCode(), generateUnsignedDivisionCode(), getMul64(), getStatepointArgs(), instrumentOneFunc(), isIndirectBrTarget(), needsRuntimeRegistrationOfSectionRange(), shouldKeepInEntry(), and splitRetconCoroutine().
|
inline |
Fetch the type representing a 64-bit integer.
Definition at line 388 of file IRBuilder.h.
References llvm::Type::getInt64Ty().
Referenced by llvm::createAArch64StackTaggingPass(), CreateInvariantStart(), CreateLifetimeEnd(), CreateLifetimeStart(), createPrivateNonConstGlobalForString(), llvm::expandDivisionUpTo64Bits(), llvm::expandRemainderUpTo64Bits(), getIntrinsicForMaskedAtomicRMWBinOp(), getMul64(), getOrInsertGlobal(), INITIALIZE_PASS(), instrumentOneFunc(), isIndirectBrTarget(), llvm::log2(), postDominates(), llvm::ModuleSanitizerCoveragePass::run(), and shouldKeepInEntry().
|
inline |
Get a constant 8-bit value.
Definition at line 333 of file IRBuilder.h.
References llvm::ConstantInt::get().
Referenced by annotateNonNullAndDereferenceable(), convert_i1_to_i8(), createResumeEntryBlock(), isReportingError(), and shouldKeepInEntry().
|
inline |
Fetch the type representing a pointer to an 8-bit integer value.
Definition at line 421 of file IRBuilder.h.
References llvm::Type::getInt8PtrTy().
Referenced by llvm::castToCStr(), llvm::SanitizerStatReport::create(), llvm::createAArch64StackTaggingPass(), createOrdering(), createPrivateNonConstGlobalForString(), CreatePrologue(), llvm::createSeparateConstOffsetFromGEPPass(), llvm::createThreadSanitizerLegacyPassPass(), llvm::emitBCmp(), llvm::emitCalloc(), llvm::emitFGetSUnlocked(), llvm::emitFPutS(), llvm::emitFPutSUnlocked(), llvm::emitFReadUnlocked(), llvm::emitFWrite(), llvm::emitFWriteUnlocked(), llvm::emitMalloc(), llvm::emitMemCCpy(), llvm::emitMemChr(), llvm::emitMemCmp(), llvm::emitMemCpyChk(), llvm::emitPutS(), llvm::emitSNPrintf(), llvm::emitSPrintf(), llvm::emitStpCpy(), llvm::emitStpNCpy(), llvm::emitStrCat(), llvm::emitStrChr(), llvm::emitStrCpy(), llvm::emitStrDup(), llvm::emitStrLCat(), llvm::emitStrLCpy(), llvm::emitStrLen(), llvm::emitStrNCat(), llvm::emitStrNCmp(), llvm::emitStrNCpy(), llvm::emitVSNPrintf(), llvm::emitVSPrintf(), getCurrentFunctionReturnType(), getOrInsertGlobal(), getSignature(), getStackGuard(), getSuccState(), GlobalWasGeneratedByCompiler(), handleNoSuspendCoroutine(), INITIALIZE_PASS(), instrumentMaskedLoadOrStore(), isAtomic(), isIndirectBrTarget(), IsNonLocalValue(), llvm::ARMTargetLowering::lowerInterleavedLoad(), llvm::ARMTargetLowering::lowerInterleavedStore(), lowerSubFn(), MarkBlocksLiveIn(), mayLoopAccessLocation(), postDominates(), RetagMask(), llvm::HWAddressSanitizerPass::run(), shouldKeepInEntry(), TypeSizeToSizeIndex(), llvm::UpgradeGlobalVariable(), and UseTlsOffset().
|
inline |
Fetch the type representing an 8-bit integer.
Definition at line 373 of file IRBuilder.h.
References llvm::Type::getInt8Ty().
Referenced by annotateNonNullAndDereferenceable(), createPrivateNonConstGlobalForString(), createResumeEntryBlock(), llvm::createSeparateConstOffsetFromGEPPass(), getAllocaSizeInBytes(), getOrInsertGlobal(), instrumentMaskedLoadOrStore(), IsNonLocalValue(), isReportingError(), llvm::LibCallSimplifier::LibCallSimplifier(), lowerLocalAllocas(), optimizeMemCmpConstantSize(), RetagMask(), llvm::HWAddressSanitizerPass::run(), llvm::ModuleSanitizerCoveragePass::run(), shouldKeepInEntry(), simplifyX86addcarry(), TypeSizeToSizeIndex(), unifyBitWidth(), UpgradeX86PSLLDQIntrinsics(), UpgradeX86PSRLDQIntrinsics(), and UseTlsOffset().
|
inline |
Get a constant N-bit value, zero extended or truncated from a 64-bit value.
Definition at line 354 of file IRBuilder.h.
References llvm::ConstantInt::get().
Referenced by annotateNonNullAndDereferenceable(), and getIntrinsicForMaskedAtomicRMWBinOp().
|
inline |
Fetch the type representing an N-bit integer.
Definition at line 396 of file IRBuilder.h.
References llvm::Type::getIntNTy().
Referenced by annotateNonNullAndDereferenceable(), ApplyX86MaskOn1BitsVec(), createCmpXchgInstFun(), llvm::HexagonTargetLowering::emitLoadLinked(), llvm::AArch64TargetLowering::emitLoadLinked(), llvm::HexagonTargetLowering::emitStoreConditional(), llvm::AArch64TargetLowering::emitStoreConditional(), getMulHu(), getOrInsertGlobal(), simplifyX86movmsk(), and TypeSizeToSizeIndex().
|
inline |
Fetch the type representing a pointer to an integer value.
Definition at line 426 of file IRBuilder.h.
References llvm::DataLayout::getIntPtrType().
Referenced by llvm::SanitizerStatReport::create(), getOrInsertGlobal(), mayLoopAccessLocation(), and llvm::HWAddressSanitizerPass::run().
|
inline |
Query for the use of constrained floating point math.
Definition at line 234 of file IRBuilder.h.
|
inline |
Get the constant value for i1 true.
Definition at line 323 of file IRBuilder.h.
References llvm::ConstantInt::getTrue().
Referenced by createFFSIntrinsic(), llvm::InnerLoopVectorizer::createVectorizedLoopSkeleton(), llvm::VPBranchOnMaskRecipe::execute(), foldCttzCtlz(), generateUnsignedDivisionCode(), insertSinCosCall(), and llvm::LoopPredicationPass::run().
|
inline |
Fetch the type representing void.
Definition at line 416 of file IRBuilder.h.
References llvm::Type::getVoidTy().
Referenced by llvm::SanitizerStatReport::create(), createPrivateNonConstGlobalForString(), llvm::createThreadSanitizerLegacyPassPass(), getOrInsertGlobal(), getSignature(), instrumentMaskedLoadOrStore(), llvm::HWAddressSanitizerPass::run(), llvm::ModuleSanitizerCoveragePass::run(), shouldKeepInEntry(), and TypeSizeToSizeIndex().
|
inline |
Sets the current insert point to a previously-saved location.
Definition at line 205 of file IRBuilder.h.
References llvm::IRBuilderBase::InsertPoint::getBlock(), llvm::IRBuilderBase::InsertPoint::getPoint(), and llvm::IRBuilderBase::InsertPoint::isSet().
Referenced by llvm::InnerLoopVectorizer::getOrCreateVectorValue(), and llvm::IRBuilderBase::InsertPointGuard::~InsertPointGuard().
|
inline |
Returns the current insert point, clearing it in the process.
Definition at line 198 of file IRBuilder.h.
|
inline |
Returns the current insert point.
Definition at line 193 of file IRBuilder.h.
Referenced by llvm::InnerLoopVectorizer::getOrCreateVectorValue().
|
inline |
Set location information used by debugging information.
Definition at line 156 of file IRBuilder.h.
Referenced by canFoldIVIncExpr(), llvm::createAMDGPUPrintfRuntimeBinding(), createFFSIntrinsic(), CreatePrologue(), getMulHu(), insertValues(), promotedOpIsNUW(), llvm::SCEVExpander::replaceCongruentIVs(), llvm::SCEVExpander::SetCurrentDebugLocation(), llvm::InnerLoopVectorizer::setDebugLocFromInst(), shouldKeepFDivF32(), SimplifyIndirectBrOnSelect(), simplifyRelocatesOffABase(), and llvm::IRBuilderBase::InsertPointGuard::~InsertPointGuard().
|
inline |
Set the exception handling to be used with constrained floating point.
Definition at line 237 of file IRBuilder.h.
|
inline |
Set the rounding mode handling to be used with constrained floating point.
Definition at line 243 of file IRBuilder.h.
|
inline |
Set the floating point math metadata to be used.
Definition at line 222 of file IRBuilder.h.
|
inline |
Set the fast-math flags to be used with generated fp-math operators.
Definition at line 225 of file IRBuilder.h.
Referenced by buildMultiplyTree(), llvm::createMinMaxOp(), createPowWithIntegerExponent(), llvm::createTargetReduction(), llvm::AMDGPULibCalls::fold(), getMulHu(), optimizeBinaryDoubleFP(), optimizeDoubleFP(), optimizeTrigReflections(), replaceUnaryCall(), shouldKeepFDivF32(), and llvm::InstCombiner::visitFDiv().
|
inline |
This specifies that created instructions should be appended to the end of the specified block.
Definition at line 132 of file IRBuilder.h.
References llvm::BasicBlock::end().
Referenced by canonicalizeSaturatedAdd(), Cleanup(), combineLoadToOperationType(), llvm::ObjectSizeOffsetEvaluator::compute(), llvm::createAMDGPUPrintfRuntimeBinding(), createFFSIntrinsic(), createResumeEntryBlock(), createRetPHINode(), llvm::InnerLoopVectorizer::createVectorizedLoopSkeleton(), despeculateCountZeros(), llvm::orc::IRSpeculationLayer::emit(), emitSetAndGetSwiftErrorValueAround(), eraseDeadBBsAndChildren(), llvm::VPBasicBlock::execute(), llvm::VPlan::execute(), FitWeights(), llvm::InnerLoopVectorizer::fixFirstOrderRecurrence(), llvm::InnerLoopVectorizer::fixLCSSAPHIs(), llvm::InnerLoopVectorizer::fixNonInductionPHIs(), llvm::InnerLoopVectorizer::fixReduction(), llvm::AMDGPULibCalls::fold(), FoldTwoEntryPHINode(), generatedUnsignedRemainderCode(), generateSignedDivisionCode(), generateSignedRemainderCode(), llvm::InnerLoopVectorizer::getBroadcastInstrs(), getNarrowIntrinsic(), llvm::InnerLoopVectorizer::getOrCreateVectorValue(), getScalarIntrinsicDeclaration(), getSignature(), insertSinCosCall(), instrumentMaskedLoadOrStore(), isCallPromotable(), isKnownTypeIdMember(), isReInterleaveMask(), lowerLocalAllocas(), llvm::lowerObjectSizeCall(), lowerSubFn(), llvm::EscapeEnumerator::Next(), optimizeMemCmpConstantSize(), performMaskedAtomicOp(), processUGT_ADDCST_ADD(), processUMulZExtIdiom(), ReduceSwitchRange(), removeBitcastsFromLoadStoreOnMinMax(), removeUndefIntroducingPredecessor(), RetagMask(), setInsertionPoint(), llvm::SCEVExpander::setInsertPoint(), shouldKeepInEntry(), SimplifyCondBranchToTwoReturns(), SimplifyIndirectBrOnSelect(), splitMergedValStore(), SwitchToLookupTable(), TypeSizeToSizeIndex(), llvm::UpgradeIntrinsicCall(), visitIVCast(), and llvm::ObjectSizeOffsetEvaluator::visitPHINode().
|
inline |
This specifies that created instructions should be inserted before the specified instruction.
Definition at line 139 of file IRBuilder.h.
References assert(), llvm::BasicBlock::end(), llvm::Instruction::getDebugLoc(), llvm::ilist_node_impl< OptionsT >::getIterator(), and llvm::Instruction::getParent().
|
inline |
This specifies that created instructions should be inserted at the specified point.
Definition at line 148 of file IRBuilder.h.
References llvm::BasicBlock::end().
|
inline |
If this builder has a current debug location, set it on the specified instruction.
Definition at line 163 of file IRBuilder.h.
References llvm::Instruction::setDebugLoc().
Referenced by createCallHelper(), createInvokeHelper(), and getCurrentFunctionReturnType().
|
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 231 of file IRBuilder.h.
|
protected |
Definition at line 92 of file IRBuilder.h.
Referenced by CreateBinaryIntrinsic(), CreateElementUnorderedAtomicMemCpy(), CreateElementUnorderedAtomicMemMove(), CreateElementUnorderedAtomicMemSet(), CreateGCRelocate(), CreateGCResult(), CreateGlobalString(), CreateIntrinsic(), CreateInvariantStart(), CreateLifetimeEnd(), CreateLifetimeStart(), CreateMaskedStore(), CreateMemCpy(), CreateMemMove(), CreateMemSet(), CreateUnaryIntrinsic(), and getCurrentFunctionReturnType().
|
protected |
Definition at line 94 of file IRBuilder.h.
Referenced by CreateGlobalString(), CreateMaskedGather(), and CreateMaskedScatter().
|
protected |
Definition at line 100 of file IRBuilder.h.
|
protected |
Definition at line 101 of file IRBuilder.h.
|
protected |
Definition at line 96 of file IRBuilder.h.
Referenced by llvm::IRBuilderBase::FastMathFlagGuard::~FastMathFlagGuard().
|
protected |
Definition at line 103 of file IRBuilder.h.
|
protected |
Definition at line 97 of file IRBuilder.h.
Referenced by CreateFPMaxReduce(), CreateFPMinReduce(), and llvm::IRBuilderBase::FastMathFlagGuard::~FastMathFlagGuard().
|
protected |
Definition at line 93 of file IRBuilder.h.
Referenced by getCurrentFunctionReturnType().
|
protected |
Definition at line 99 of file IRBuilder.h.