clang 18.0.0git
|
An aligned address. More...
#include "/home/buildbot/as-worker-4/publish-doxygen-docs/llvm-project/clang/lib/CodeGen/Address.h"
Public Member Functions | |
Address (llvm::Value *Pointer, llvm::Type *ElementType, CharUnits Alignment, KnownNonNull_t IsKnownNonNull=NotKnownNonNull) | |
bool | isValid () const |
llvm::Value * | getPointer () const |
llvm::PointerType * | getType () const |
Return the type of the pointer value. | |
llvm::Type * | getElementType () const |
Return the type of the values stored in this address. | |
unsigned | getAddressSpace () const |
Return the address space that this address resides in. | |
llvm::StringRef | getName () const |
Return the IR name of the pointer value. | |
CharUnits | getAlignment () const |
Return the alignment of this pointer. | |
Address | withPointer (llvm::Value *NewPointer, KnownNonNull_t IsKnownNonNull) const |
Return address with different pointer, but same element type and alignment. | |
Address | withAlignment (CharUnits NewAlignment) const |
Return address with different alignment, but same pointer and element type. | |
Address | withElementType (llvm::Type *ElemTy) const |
Return address with different element type, but same pointer and alignment. | |
KnownNonNull_t | isKnownNonNull () const |
Whether the pointer is known not to be null. | |
Address | setKnownNonNull () |
Set the non-null bit. | |
Static Public Member Functions | |
static Address | invalid () |
Protected Member Functions | |
Address (std::nullptr_t) | |
|
inlineprotected |
|
inline |
|
inline |
|
inline |
Return the alignment of this pointer.
Definition at line 78 of file Address.h.
References isValid().
Referenced by ApplyNonVirtualAndVirtualOffset(), clang::CodeGen::ConstantAddress::castImpl(), CheckAtomicAlignment(), CreateCoercedLoad(), CreateCoercedStore(), clang::CodeGen::CGBuilderTy::CreateConstArrayGEP(), clang::CodeGen::CGBuilderTy::CreateConstByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP2_32(), clang::CodeGen::CGBuilderTy::CreateGEP(), clang::CodeGen::CGBuilderTy::CreateLoad(), createLoadInstBefore(), clang::CodeGen::CGBuilderTy::CreateMemCpy(), clang::CodeGen::CGBuilderTy::CreateMemCpyInline(), clang::CodeGen::CGBuilderTy::CreateMemMove(), clang::CodeGen::CGBuilderTy::CreateMemSet(), clang::CodeGen::CGBuilderTy::CreateMemSetInline(), clang::CodeGen::CGBuilderTy::CreatePointerBitCastOrAddrSpaceCast(), clang::CodeGen::CGBuilderTy::CreatePreserveStructAccessIndex(), clang::CodeGen::CGBuilderTy::CreateStore(), createStoreInstBefore(), clang::CodeGen::CGBuilderTy::CreateStructGEP(), clang::CodeGen::CodeGenFunction::CXXDefaultInitExprScope::CXXDefaultInitExprScope(), EmitArrayDelete(), emitArraySubscriptGEP(), emitGlobalToListCopyFunction(), emitListToGlobalCopyFunction(), clang::CodeGen::emitMergePHI(), emitNonZeroVLAInit(), EmitNullBaseClassInitialization(), EmitOMPAggregateInit(), EmitOMPAggregateReduction(), emitStoresForConstant(), clang::CodeGen::CGOpenMPRuntime::emitThreadPrivateVarDefinition(), clang::CodeGen::CGOpenMPRuntime::emitUserDefinedMapper(), forConstantArrayExpansion(), clang::CodeGen::CodeGenFunction::ParamValue::forIndirect(), clang::CodeGen::CGOpenMPRuntime::getAddrOfThreadPrivate(), clang::CodeGen::CodeGenFunction::OMPBuilderCBHelpers::getAddrOfThreadPrivate(), clang::CodeGen::RValue::getAggregate(), clang::CodeGen::AggValueSlot::getAlignment(), clang::CodeGen::LValue::MakeAddr(), clang::CodeGen::LValue::MakeBitfield(), clang::CodeGen::LValue::MakeExtVectorElt(), clang::CodeGen::LValue::MakeMatrixElt(), clang::CodeGen::LValue::MakeVectorElt(), clang::CodeGen::DominatingValue< Address >::save(), clang::CodeGen::EHCleanupScope::setActiveFlag(), clang::CodeGen::LValue::setAddress(), clang::CodeGen::CodeGenFunction::setBeforeOutermostConditional(), shuffleAndStore(), withElementType(), clang::CodeGen::ConstantAddress::withElementType(), and withPointer().
|
inline |
Return the type of the values stored in this address.
Definition at line 62 of file Address.h.
References isValid().
Referenced by clang::CodeGen::ReductionCodeGen::adjustPrivateAddress(), clang::CodeGen::ConstantAddress::castImpl(), castToBase(), CheckAtomicAlignment(), CreateCoercedLoad(), CreateCoercedStore(), clang::CodeGen::CGBuilderTy::CreateConstArrayGEP(), clang::CodeGen::CGBuilderTy::CreateConstByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP2_32(), clang::CodeGen::CGBuilderTy::CreateGEP(), clang::CodeGen::CGBuilderTy::CreateLoad(), createLoadInstBefore(), clang::CodeGen::CGBuilderTy::CreatePreserveStructAccessIndex(), clang::CodeGen::CGBuilderTy::CreateStructGEP(), emitARCStoreOperation(), EmitArrayDelete(), emitArraySubscriptGEP(), EmitCheckedMixedSignMultiply(), clang::CodeGen::CGOpenMPRuntime::emitDestroyClause(), clang::CodeGen::emitMergePHI(), emitNonZeroVLAInit(), EmitOMPAggregateInit(), EmitOMPAggregateReduction(), emitOMPArraySectionBase(), emitOMPAtomicCompareExpr(), EmitPointerWithAlignment(), emitStoresForPatternInit(), emitStoresForZeroInit(), clang::CodeGen::CGOpenMPRuntime::emitTaskReductionInit(), clang::CodeGen::emitVoidPtrDirectVAArg(), emitWriteback(), EnterStructPointerForCoercedAccess(), findDominatingStoreToReturnValue(), forConstantArrayExpansion(), clang::CodeGen::CodeGenFunction::ParamValue::forIndirect(), clang::CodeGen::CGOpenMPRuntime::getAddrOfThreadPrivate(), clang::CodeGen::CodeGenFunction::OMPBuilderCBHelpers::getAddrOfThreadPrivate(), clang::CodeGen::RValue::getAggregate(), getNullForVariable(), getPointerAndSize(), clang::CodeGen::LValue::MakeAddr(), clang::CodeGen::LValue::MakeBitfield(), clang::CodeGen::LValue::MakeExtVectorElt(), clang::CodeGen::LValue::MakeMatrixElt(), clang::CodeGen::LValue::MakeVectorElt(), MaybeConvertMatrixAddress(), clang::CodeGen::DominatingValue< Address >::save(), clang::CodeGen::LValue::setAddress(), shuffleAndStore(), tryEmitARCCopyWeakInit(), withAlignment(), and withPointer().
|
inline |
Return the IR name of the pointer value.
Definition at line 73 of file Address.h.
References getPointer().
Referenced by CreateCoercedLoad().
|
inline |
Definition at line 51 of file Address.h.
References isValid().
Referenced by clang::CodeGen::ReductionCodeGen::adjustPrivateAddress(), clang::CodeGen::CGOpenMPRuntimeGPU::adjustTargetSpecificDataForLambdas(), ApplyNonVirtualAndVirtualOffset(), clang::CodeGen::CGObjCRuntime::canMessageReceiverBeNull(), clang::CodeGen::ConstantAddress::castImpl(), castToBase(), castValueFromUintptr(), CheckAtomicAlignment(), clang::CodeGen::CGBuilderTy::CreateAddrSpaceCast(), CreateCoercedLoad(), CreateCoercedStore(), clang::CodeGen::CGBuilderTy::CreateConstArrayGEP(), clang::CodeGen::CGBuilderTy::CreateConstByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP2_32(), clang::CodeGen::CGBuilderTy::CreateGEP(), clang::CodeGen::CGBuilderTy::CreateLaunderInvariantGroup(), clang::CodeGen::CGBuilderTy::CreateLoad(), createLoadInstBefore(), clang::CodeGen::CGBuilderTy::CreateMemCpy(), clang::CodeGen::CGBuilderTy::CreateMemCpyInline(), clang::CodeGen::CGBuilderTy::CreateMemMove(), clang::CodeGen::CGBuilderTy::CreateMemSet(), clang::CodeGen::CGBuilderTy::CreateMemSetInline(), clang::CodeGen::CGBuilderTy::CreatePointerBitCastOrAddrSpaceCast(), clang::CodeGen::CGBuilderTy::CreatePreserveStructAccessIndex(), clang::CodeGen::CGBuilderTy::CreateStore(), createStoreInstBefore(), clang::CodeGen::CGBuilderTy::CreateStructGEP(), clang::CodeGen::CodeGenFunction::CXXDefaultInitExprScope::CXXDefaultInitExprScope(), destroyOptimisticNormalEntry(), emitARCCopyOperation(), emitARCLoadOperation(), emitARCStoreOperation(), EmitArrayDelete(), emitArraySubscriptGEP(), emitAtomicCmpXchg(), EmitAtomicOp(), EmitBitTestIntrinsic(), clang::CodeGen::CGOpenMPRuntime::emitDestroyClause(), EmitDestroyingObjectDelete(), clang::CodeGen::CGOpenMPRuntime::emitDoacrossInit(), EmitDoacrossOrdered(), clang::CodeGen::CGOpenMPRuntime::emitForNext(), emitForStaticInitCall(), emitGlobalToListCopyFunction(), emitGlobalToListReduceFunction(), emitListToGlobalCopyFunction(), emitListToGlobalReduceFunction(), clang::CodeGen::emitMergePHI(), emitNonZeroVLAInit(), EmitObjectDelete(), EmitOMPAggregateInit(), EmitOMPAggregateReduction(), emitOMPAtomicCompareExpr(), clang::CodeGen::CGOpenMPRuntime::emitParallelCall(), clang::CodeGen::CGOpenMPRuntimeGPU::emitParallelCall(), EmitPointerWithAlignment(), emitProxyTaskFunction(), clang::CodeGen::CGOpenMPRuntime::emitReduction(), clang::CodeGen::CGOpenMPRuntimeGPU::emitReduction(), emitShuffleAndReduceFunction(), clang::CodeGen::CGOpenMPRuntime::emitSingleRegion(), emitStructGetterCall(), clang::CodeGen::CGOpenMPRuntime::emitTargetDataStandAloneCall(), clang::CodeGen::CGOpenMPRuntime::emitTaskCall(), clang::CodeGen::CGOpenMPRuntime::emitTaskInit(), clang::CodeGen::CGOpenMPRuntime::emitTaskReductionInit(), clang::CodeGen::CGOpenMPRuntime::emitTaskwaitCall(), clang::CodeGen::CGOpenMPRuntimeGPU::emitTeamsCall(), clang::CodeGen::CGOpenMPRuntime::emitThreadPrivateVarInit(), clang::CodeGen::CGObjCRuntime::EmitTryCatchStmt(), EmitTypeidFromVTable(), clang::CodeGen::CGOpenMPRuntime::emitUpdateClause(), clang::CodeGen::CGOpenMPRuntime::emitUsesAllocatorsInit(), clang::CodeGen::EmitVAArgInstr(), clang::CodeGen::emitVoidPtrDirectVAArg(), emitWriteback(), emitWritebackArg(), EnterNewDeleteCleanup(), findDominatingStoreToReturnValue(), forConstantArrayExpansion(), clang::CodeGen::CodeGenFunction::ParamValue::forIndirect(), clang::CodeGen::CGOpenMPRuntime::getAddressOfLocalVariable(), clang::CodeGen::CGOpenMPRuntime::getAddrOfThreadPrivate(), clang::CodeGen::CodeGenFunction::OMPBuilderCBHelpers::getAddrOfThreadPrivate(), clang::CodeGen::RValue::getAggregate(), getName(), clang::CodeGen::ConstantAddress::getPointer(), clang::CodeGen::AggValueSlot::getPointer(), getPointerAndSize(), getType(), InitCatchParam(), clang::CodeGen::ConstantAddress::isaImpl(), clang::CodeGen::LValue::MakeAddr(), clang::CodeGen::LValue::MakeBitfield(), clang::CodeGen::LValue::MakeExtVectorElt(), clang::CodeGen::LValue::MakeMatrixElt(), clang::CodeGen::LValue::MakeVectorElt(), clang::CodeGen::DominatingValue< Address >::needsSaving(), performTypeAdjustment(), pushTemporaryCleanup(), clang::CodeGen::CGCXXABI::ReadArrayCookie(), clang::CodeGen::DominatingLLVMValue::save(), clang::CodeGen::DominatingValue< Address >::save(), clang::CodeGen::LValue::setAddress(), clang::CodeGen::CodeGenFunction::setBeforeOutermostConditional(), clang::CodeGen::CodeGenFunction::OMPMapVars::setVarAddr(), shuffleAndStore(), tryRemoveRetainOfSelf(), withAlignment(), and withElementType().
|
inline |
Return the type of the pointer value.
Definition at line 57 of file Address.h.
References getPointer(), and getType().
Referenced by clang::CodeGen::ReductionCodeGen::adjustPrivateAddress(), castToBase(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP2_32(), emitARCCopyOperation(), emitGlobalToListCopyFunction(), clang::CodeGen::ReductionCodeGen::emitInitialization(), emitListToGlobalCopyFunction(), clang::CodeGen::emitMergePHI(), emitNonZeroVLAInit(), emitOutlinedFunctionPrologue(), EmitPointerWithAlignment(), emitPseudoObjectExpr(), clang::CodeGen::CGOpenMPRuntime::emitReduction(), getAddressSpace(), getType(), and shuffleAndStore().
|
inlinestatic |
Definition at line 46 of file Address.h.
Referenced by castToBase(), emitDeclTargetVarDeclLValue(), clang::CodeGen::CGOpenMPRuntime::emitDependClause(), clang::CodeGen::CGOpenMPRuntime::emitDepobjDependClause(), emitInterWarpCopyFunction(), clang::CodeGen::ABIInfo::EmitMSVAArg(), EmitOMPAggregateInit(), emitOutlinedFunctionPrologue(), emitReduceInitFunction(), emitScanBasedDirective(), clang::CodeGen::CGOpenMPRuntime::emitSingleRegion(), clang::CodeGen::CGOpenMPRuntime::emitTaskCall(), emitTaskDupFunction(), clang::CodeGen::CGOpenMPRuntime::emitTaskInit(), clang::CodeGen::CGOpenMPRuntime::emitTaskwaitCall(), clang::CodeGen::emitVoidPtrDirectVAArg(), clang::CodeGen::CGOpenMPRuntime::getAddressOfLocalVariable(), clang::CodeGen::CodeGenFunction::OMPBuilderCBHelpers::getAddressOfLocalVariable(), clang::CodeGen::CGOpenMPSIMDRuntime::getAddressOfLocalVariable(), clang::CodeGen::CGOpenMPRuntimeGPU::getAddressOfLocalVariable(), clang::CodeGen::CGOpenMPRuntime::getAddrOfDeclareTargetVar(), clang::CodeGen::AggValueSlot::ignored(), clang::CodeGen::CGCXXABI::InitializeArrayCookie(), clang::CodeGen::CodeGenFunction::InlinedInheritingConstructorScope::InlinedInheritingConstructorScope(), clang::CodeGen::CodeGenFunction::pushCleanupAfterFullExpr(), and clang::CodeGen::CodeGenFunction::OMPMapVars::setVarAddr().
|
inline |
Whether the pointer is known not to be null.
Definition at line 105 of file Address.h.
References isValid().
Referenced by clang::CodeGen::CGBuilderTy::CreateAddrSpaceCast(), clang::CodeGen::CGBuilderTy::CreateConstArrayGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsByteGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP(), clang::CodeGen::CGBuilderTy::CreateConstInBoundsGEP2_32(), clang::CodeGen::CGBuilderTy::CreateLaunderInvariantGroup(), clang::CodeGen::CGBuilderTy::CreatePointerBitCastOrAddrSpaceCast(), clang::CodeGen::CGBuilderTy::CreateStructGEP(), clang::CodeGen::LValue::MakeAddr(), clang::CodeGen::LValue::MakeBitfield(), clang::CodeGen::LValue::MakeExtVectorElt(), clang::CodeGen::LValue::MakeMatrixElt(), clang::CodeGen::LValue::MakeVectorElt(), clang::CodeGen::LValue::setAddress(), withAlignment(), and withElementType().
|
inline |
Definition at line 47 of file Address.h.
Referenced by castToBase(), CheckAggExprForMemSetUse(), EmitCleanup(), EmitGlobalVarDeclLValue(), emitPrivatesInit(), clang::CodeGen::CGOpenMPRuntime::emitSingleRegion(), clang::CodeGen::AggValueSlot::forAddr(), clang::CodeGen::CGOpenMPRuntime::getAddressOfLocalVariable(), getAlignment(), getElementType(), getPointer(), clang::CodeGen::EHCleanupScope::hasActiveFlag(), clang::CodeGen::AggValueSlot::isIgnored(), isKnownNonNull(), clang::CodeGen::ReturnValueSlot::isNull(), clang::CodeGen::CodeGenFunction::pushCleanupAfterFullExprWithActiveFlag(), setKnownNonNull(), and SetupCleanupBlockActivation().
|
inline |
Set the non-null bit.
Definition at line 111 of file Address.h.
References isValid().
Referenced by clang::CodeGen::AggValueSlot::forAddr().
Return address with different alignment, but same pointer and element type.
Definition at line 93 of file Address.h.
References getElementType(), getPointer(), and isKnownNonNull().
Referenced by emitOutlinedFunctionPrologue(), and emitPrivatesInit().
|
inline |
Return address with different element type, but same pointer and alignment.
Definition at line 100 of file Address.h.
References getAlignment(), getPointer(), and isKnownNonNull().
Referenced by castValueToType(), CheckAggExprForMemSetUse(), complexTempStructure(), CreateCoercedLoad(), CreateCoercedStore(), createUnnamedGlobalForMemcpyFrom(), emitAddressAtOffset(), EmitAsmStores(), clang::CodeGen::ReductionCodeGen::emitCleanups(), emitNonZeroVLAInit(), EmitNullBaseClassInitialization(), emitOMPArraySectionBase(), EmitPointerWithAlignment(), emitReduceCombFunction(), emitReduceInitFunction(), emitStoresForConstant(), EmitThreadPrivateVarDeclLValue(), clang::CodeGen::emitVoidPtrDirectVAArg(), clang::CodeGen::CGOpenMPRuntime::getDepobjElements(), loadToBegin(), MaybeConvertMatrixAddress(), performTypeAdjustment(), clang::CodeGen::CGCXXABI::ReadArrayCookie(), and tryEmitARCCopyWeakInit().
|
inline |
Return address with different pointer, but same element type and alignment.
Definition at line 85 of file Address.h.
References getAlignment(), and getElementType().
Referenced by castToBase(), clang::CodeGen::CGBuilderTy::CreateAddrSpaceCast(), and clang::CodeGen::CGBuilderTy::CreateLaunderInvariantGroup().