clang 20.0.0git
Public Member Functions | Friends | List of all members
clang::CodeGen::CGBuilderTy Class Reference

#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/CodeGen/CGBuilder.h"

Inheritance diagram for clang::CodeGen::CGBuilderTy:
Inheritance graph
[legend]

Public Member Functions

 CGBuilderTy (const CodeGenTypeCache &TypeCache, llvm::LLVMContext &C)
 
 CGBuilderTy (const CodeGenTypeCache &TypeCache, llvm::LLVMContext &C, const llvm::ConstantFolder &F, const CGBuilderInserterTy &Inserter)
 
 CGBuilderTy (const CodeGenTypeCache &TypeCache, llvm::Instruction *I)
 
 CGBuilderTy (const CodeGenTypeCache &TypeCache, llvm::BasicBlock *BB)
 
llvm::ConstantInt * getSize (CharUnits N)
 
llvm::ConstantInt * getSize (uint64_t N)
 
llvm::LoadInst * CreateLoad (Address Addr, const llvm::Twine &Name="")
 
llvm::LoadInst * CreateLoad (Address Addr, const char *Name)
 
llvm::LoadInst * CreateLoad (Address Addr, bool IsVolatile, const llvm::Twine &Name="")
 
llvm::LoadInst * CreateAlignedLoad (llvm::Type *Ty, llvm::Value *Addr, CharUnits Align, const llvm::Twine &Name="")
 
llvm::StoreInst * CreateStore (llvm::Value *Val, Address Addr, bool IsVolatile=false)
 
llvm::StoreInst * CreateAlignedStore (llvm::Value *Val, llvm::Value *Addr, CharUnits Align, bool IsVolatile=false)
 
llvm::StoreInst * CreateDefaultAlignedStore (llvm::Value *Val, llvm::Value *Addr, bool IsVolatile=false)
 
llvm::LoadInst * CreateFlagLoad (llvm::Value *Addr, const llvm::Twine &Name="")
 Emit a load from an i1 flag variable.
 
llvm::StoreInst * CreateFlagStore (bool Value, llvm::Value *Addr)
 Emit a store to an i1 flag variable.
 
llvm::AtomicCmpXchgInst * CreateAtomicCmpXchg (Address Addr, llvm::Value *Cmp, llvm::Value *New, llvm::AtomicOrdering SuccessOrdering, llvm::AtomicOrdering FailureOrdering, llvm::SyncScope::ID SSID=llvm::SyncScope::System)
 
llvm::AtomicRMWInst * CreateAtomicRMW (llvm::AtomicRMWInst::BinOp Op, Address Addr, llvm::Value *Val, llvm::AtomicOrdering Ordering, llvm::SyncScope::ID SSID=llvm::SyncScope::System)
 
Address CreateAddrSpaceCast (Address Addr, llvm::Type *Ty, llvm::Type *ElementTy, const llvm::Twine &Name="")
 
Address CreatePointerBitCastOrAddrSpaceCast (Address Addr, llvm::Type *Ty, llvm::Type *ElementTy, const llvm::Twine &Name="")
 
Address CreateStructGEP (Address Addr, unsigned Index, const llvm::Twine &Name="")
 
Address CreateConstArrayGEP (Address Addr, uint64_t Index, const llvm::Twine &Name="")
 Given addr = [n x T]* ... produce name = getelementptr inbounds addr, i64 0, i64 index where i64 is actually the target word size.
 
Address CreateConstInBoundsGEP (Address Addr, uint64_t Index, const llvm::Twine &Name="")
 Given addr = T* ... produce name = getelementptr inbounds addr, i64 index where i64 is actually the target word size.
 
Address CreateConstGEP (Address Addr, uint64_t Index, const llvm::Twine &Name="")
 Given addr = T* ... produce name = getelementptr inbounds addr, i64 index where i64 is actually the target word size.
 
Address CreateGEP (CodeGenFunction &CGF, Address Addr, llvm::Value *Index, const llvm::Twine &Name="")
 
Address CreateConstInBoundsByteGEP (Address Addr, CharUnits Offset, const llvm::Twine &Name="")
 Given a pointer to i8, adjust it by a given constant offset.
 
Address CreateConstByteGEP (Address Addr, CharUnits Offset, const llvm::Twine &Name="")
 
Address CreateConstInBoundsGEP2_32 (Address Addr, unsigned Idx0, unsigned Idx1, const llvm::Twine &Name="")
 
Address CreateConstGEP2_32 (Address Addr, unsigned Idx0, unsigned Idx1, const llvm::Twine &Name="")
 
Address CreateGEP (Address Addr, ArrayRef< llvm::Value * > IdxList, llvm::Type *ElementType, CharUnits Align, const Twine &Name="")
 
Address CreateInBoundsGEP (Address Addr, ArrayRef< llvm::Value * > IdxList, llvm::Type *ElementType, CharUnits Align, const Twine &Name="")
 
llvm::Value * CreateIsNull (Address Addr, const Twine &Name="")
 
llvm::CallInst * CreateMemCpy (Address Dest, Address Src, llvm::Value *Size, bool IsVolatile=false)
 
llvm::CallInst * CreateMemCpy (Address Dest, Address Src, uint64_t Size, bool IsVolatile=false)
 
llvm::CallInst * CreateMemCpyInline (Address Dest, Address Src, uint64_t Size)
 
llvm::CallInst * CreateMemMove (Address Dest, Address Src, llvm::Value *Size, bool IsVolatile=false)
 
llvm::CallInst * CreateMemSet (Address Dest, llvm::Value *Value, llvm::Value *Size, bool IsVolatile=false)
 
llvm::CallInst * CreateMemSetInline (Address Dest, llvm::Value *Value, uint64_t Size)
 
Address CreatePreserveStructAccessIndex (Address Addr, unsigned Index, unsigned FieldIndex, llvm::MDNode *DbgInfo)
 
Address CreatePreserveUnionAccessIndex (Address Addr, unsigned FieldIndex, llvm::MDNode *DbgInfo)
 
Address CreateLaunderInvariantGroup (Address Addr)
 
Address CreateStripInvariantGroup (Address Addr)
 

Friends

class Address
 

Detailed Description

Definition at line 49 of file CGBuilder.h.

Constructor & Destructor Documentation

◆ CGBuilderTy() [1/4]

clang::CodeGen::CGBuilderTy::CGBuilderTy ( const CodeGenTypeCache TypeCache,
llvm::LLVMContext &  C 
)
inline

Definition at line 87 of file CGBuilder.h.

◆ CGBuilderTy() [2/4]

clang::CodeGen::CGBuilderTy::CGBuilderTy ( const CodeGenTypeCache TypeCache,
llvm::LLVMContext &  C,
const llvm::ConstantFolder &  F,
const CGBuilderInserterTy Inserter 
)
inline

Definition at line 89 of file CGBuilder.h.

◆ CGBuilderTy() [3/4]

clang::CodeGen::CGBuilderTy::CGBuilderTy ( const CodeGenTypeCache TypeCache,
llvm::Instruction *  I 
)
inline

Definition at line 93 of file CGBuilder.h.

◆ CGBuilderTy() [4/4]

clang::CodeGen::CGBuilderTy::CGBuilderTy ( const CodeGenTypeCache TypeCache,
llvm::BasicBlock *  BB 
)
inline

Definition at line 95 of file CGBuilder.h.

Member Function Documentation

◆ CreateAddrSpaceCast()

Address clang::CodeGen::CGBuilderTy::CreateAddrSpaceCast ( Address  Addr,
llvm::Type *  Ty,
llvm::Type *  ElementTy,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateAlignedLoad()

llvm::LoadInst * clang::CodeGen::CGBuilderTy::CreateAlignedLoad ( llvm::Type *  Ty,
llvm::Value *  Addr,
CharUnits  Align,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateAlignedStore()

llvm::StoreInst * clang::CodeGen::CGBuilderTy::CreateAlignedStore ( llvm::Value *  Val,
llvm::Value *  Addr,
CharUnits  Align,
bool  IsVolatile = false 
)
inline

◆ CreateAtomicCmpXchg()

llvm::AtomicCmpXchgInst * clang::CodeGen::CGBuilderTy::CreateAtomicCmpXchg ( Address  Addr,
llvm::Value *  Cmp,
llvm::Value *  New,
llvm::AtomicOrdering  SuccessOrdering,
llvm::AtomicOrdering  FailureOrdering,
llvm::SyncScope::ID  SSID = llvm::SyncScope::System 
)
inline

◆ CreateAtomicRMW()

llvm::AtomicRMWInst * clang::CodeGen::CGBuilderTy::CreateAtomicRMW ( llvm::AtomicRMWInst::BinOp  Op,
Address  Addr,
llvm::Value *  Val,
llvm::AtomicOrdering  Ordering,
llvm::SyncScope::ID  SSID = llvm::SyncScope::System 
)
inline

◆ CreateConstArrayGEP()

Address clang::CodeGen::CGBuilderTy::CreateConstArrayGEP ( Address  Addr,
uint64_t  Index,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateConstByteGEP()

Address clang::CodeGen::CGBuilderTy::CreateConstByteGEP ( Address  Addr,
CharUnits  Offset,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateConstGEP()

Address clang::CodeGen::CGBuilderTy::CreateConstGEP ( Address  Addr,
uint64_t  Index,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateConstGEP2_32()

Address clang::CodeGen::CGBuilderTy::CreateConstGEP2_32 ( Address  Addr,
unsigned  Idx0,
unsigned  Idx1,
const llvm::Twine &  Name = "" 
)
inline

Definition at line 330 of file CGBuilder.h.

Referenced by forConstantArrayExpansion().

◆ CreateConstInBoundsByteGEP()

Address clang::CodeGen::CGBuilderTy::CreateConstInBoundsByteGEP ( Address  Addr,
CharUnits  Offset,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateConstInBoundsGEP()

Address clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP ( Address  Addr,
uint64_t  Index,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateConstInBoundsGEP2_32()

Address clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP2_32 ( Address  Addr,
unsigned  Idx0,
unsigned  Idx1,
const llvm::Twine &  Name = "" 
)
inline

Definition at line 324 of file CGBuilder.h.

◆ CreateDefaultAlignedStore()

llvm::StoreInst * clang::CodeGen::CGBuilderTy::CreateDefaultAlignedStore ( llvm::Value *  Val,
llvm::Value *  Addr,
bool  IsVolatile = false 
)
inline

Definition at line 150 of file CGBuilder.h.

◆ CreateFlagLoad()

llvm::LoadInst * clang::CodeGen::CGBuilderTy::CreateFlagLoad ( llvm::Value *  Addr,
const llvm::Twine &  Name = "" 
)
inline

Emit a load from an i1 flag variable.

Definition at line 157 of file CGBuilder.h.

References CreateAlignedLoad(), and clang::CharUnits::One().

Referenced by clang::CodeGen::CodeGenFunction::pushCleanupAndDeferDeactivation().

◆ CreateFlagStore()

llvm::StoreInst * clang::CodeGen::CGBuilderTy::CreateFlagStore ( bool  Value,
llvm::Value *  Addr 
)
inline

◆ CreateGEP() [1/2]

Address clang::CodeGen::CGBuilderTy::CreateGEP ( Address  Addr,
ArrayRef< llvm::Value * >  IdxList,
llvm::Type *  ElementType,
CharUnits  Align,
const Twine &  Name = "" 
)
inline

Definition at line 335 of file CGBuilder.h.

References CreateGEP(), and clang::CodeGen::Address::getElementType().

◆ CreateGEP() [2/2]

Address clang::CodeGen::CGBuilderTy::CreateGEP ( CodeGenFunction CGF,
Address  Addr,
llvm::Value *  Index,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateInBoundsGEP()

Address clang::CodeGen::CGBuilderTy::CreateInBoundsGEP ( Address  Addr,
ArrayRef< llvm::Value * >  IdxList,
llvm::Type *  ElementType,
CharUnits  Align,
const Twine &  Name = "" 
)
inline

◆ CreateIsNull()

llvm::Value * clang::CodeGen::CGBuilderTy::CreateIsNull ( Address  Addr,
const Twine &  Name = "" 
)
inline

◆ CreateLaunderInvariantGroup()

Address clang::CodeGen::CGBuilderTy::CreateLaunderInvariantGroup ( Address  Addr)
inline

◆ CreateLoad() [1/3]

llvm::LoadInst * clang::CodeGen::CGBuilderTy::CreateLoad ( Address  Addr,
bool  IsVolatile,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateLoad() [2/3]

llvm::LoadInst * clang::CodeGen::CGBuilderTy::CreateLoad ( Address  Addr,
const char *  Name 
)
inline

◆ CreateLoad() [3/3]

llvm::LoadInst * clang::CodeGen::CGBuilderTy::CreateLoad ( Address  Addr,
const llvm::Twine &  Name = "" 
)
inline

◆ CreateMemCpy() [1/2]

llvm::CallInst * clang::CodeGen::CGBuilderTy::CreateMemCpy ( Address  Dest,
Address  Src,
llvm::Value *  Size,
bool  IsVolatile = false 
)
inline

◆ CreateMemCpy() [2/2]

llvm::CallInst * clang::CodeGen::CGBuilderTy::CreateMemCpy ( Address  Dest,
Address  Src,
uint64_t  Size,
bool  IsVolatile = false 
)
inline

◆ CreateMemCpyInline()

llvm::CallInst * clang::CodeGen::CGBuilderTy::CreateMemCpyInline ( Address  Dest,
Address  Src,
uint64_t  Size 
)
inline

◆ CreateMemMove()

llvm::CallInst * clang::CodeGen::CGBuilderTy::CreateMemMove ( Address  Dest,
Address  Src,
llvm::Value *  Size,
bool  IsVolatile = false 
)
inline

◆ CreateMemSet()

llvm::CallInst * clang::CodeGen::CGBuilderTy::CreateMemSet ( Address  Dest,
llvm::Value *  Value,
llvm::Value *  Size,
bool  IsVolatile = false 
)
inline

◆ CreateMemSetInline()

llvm::CallInst * clang::CodeGen::CGBuilderTy::CreateMemSetInline ( Address  Dest,
llvm::Value *  Value,
uint64_t  Size 
)
inline

◆ CreatePointerBitCastOrAddrSpaceCast()

Address clang::CodeGen::CGBuilderTy::CreatePointerBitCastOrAddrSpaceCast ( Address  Addr,
llvm::Type *  Ty,
llvm::Type *  ElementTy,
const llvm::Twine &  Name = "" 
)
inline

Definition at line 202 of file CGBuilder.h.

References CreateAddrSpaceCast(), clang::CodeGen::Address::getType(), and clang::CodeGen::Address::withElementType().

Referenced by clang::CodeGen::ReductionCodeGen::adjustPrivateAddress(), castToBase(), clang::CodeGen::CGOpenMPRuntime::checkAndEmitLastprivateConditional(), emitCopyprivateCopyFunction(), clang::CodeGen::CGOpenMPRuntime::emitDependClause(), clang::CodeGen::CGOpenMPRuntime::emitDepobjDependClause(), clang::CodeGen::CGOpenMPRuntime::emitDestroyClause(), clang::CodeGen::CGOpenMPRuntime::emitDoacrossInit(), clang::CodeGen::CGOpenMPRuntimeGPU::emitOutlinedFunctionCall(), clang::CodeGen::CGOpenMPRuntimeGPU::emitParallelCall(), emitPrivatesInit(), emitProxyTaskFunction(), clang::CodeGen::CGOpenMPRuntime::emitReduction(), clang::CodeGen::CGOpenMPRuntime::emitReductionFunction(), clang::CodeGen::CGOpenMPRuntime::emitSingleRegion(), clang::CodeGen::CGOpenMPRuntime::emitTaskInit(), clang::CodeGen::CGOpenMPRuntime::emitTaskLoopCall(), clang::CodeGen::CGOpenMPRuntime::emitTaskReductionInit(), clang::CodeGen::CGOpenMPRuntime::emitUsesAllocatorsInit(), clang::CodeGen::CGOpenMPRuntime::getAddressOfLocalVariable(), clang::CodeGen::CodeGenFunction::OMPBuilderCBHelpers::getAddressOfLocalVariable(), clang::CodeGen::CGOpenMPRuntimeGPU::getAddressOfLocalVariable(), clang::CodeGen::CGOpenMPRuntime::getAddrOfArtificialThreadPrivate(), clang::CodeGen::CGOpenMPRuntimeGPU::getParameterAddress(), and clang::CodeGen::CGOpenMPRuntime::getTaskReductionItem().

◆ CreatePreserveStructAccessIndex()

Address clang::CodeGen::CGBuilderTy::CreatePreserveStructAccessIndex ( Address  Addr,
unsigned  Index,
unsigned  FieldIndex,
llvm::MDNode *  DbgInfo 
)
inline

◆ CreatePreserveUnionAccessIndex()

Address clang::CodeGen::CGBuilderTy::CreatePreserveUnionAccessIndex ( Address  Addr,
unsigned  FieldIndex,
llvm::MDNode *  DbgInfo 
)
inline

◆ CreateStore()

llvm::StoreInst * clang::CodeGen::CGBuilderTy::CreateStore ( llvm::Value *  Val,
Address  Addr,
bool  IsVolatile = false 
)
inline

◆ CreateStripInvariantGroup()

Address clang::CodeGen::CGBuilderTy::CreateStripInvariantGroup ( Address  Addr)
inline

◆ CreateStructGEP()

Address clang::CodeGen::CGBuilderTy::CreateStructGEP ( Address  Addr,
unsigned  Index,
const llvm::Twine &  Name = "" 
)
inline

◆ getSize() [1/2]

llvm::ConstantInt * clang::CodeGen::CGBuilderTy::getSize ( CharUnits  N)
inline

◆ getSize() [2/2]

llvm::ConstantInt * clang::CodeGen::CGBuilderTy::getSize ( uint64_t  N)
inline

Definition at line 101 of file CGBuilder.h.

References clang::CodeGen::CodeGenTypeCache::SizeTy.

Friends And Related Function Documentation

◆ Address

friend class Address
friend

The documentation for this class was generated from the following file: