clang  15.0.0git
Public Member Functions | Static Public Member Functions | List of all members
clang::CodeGen::LValue Class Reference

LValue - This represents an lvalue references. More...

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

Collaboration diagram for clang::CodeGen::LValue:
Collaboration graph
[legend]

Public Member Functions

bool isSimple () const
 
bool isVectorElt () const
 
bool isBitField () const
 
bool isExtVectorElt () const
 
bool isGlobalReg () const
 
bool isMatrixElt () const
 
bool isVolatileQualified () const
 
bool isRestrictQualified () const
 
unsigned getVRQualifiers () const
 
QualType getType () const
 
Qualifiers::ObjCLifetime getObjCLifetime () const
 
bool isObjCIvar () const
 
void setObjCIvar (bool Value)
 
bool isObjCArray () const
 
void setObjCArray (bool Value)
 
bool isNonGC () const
 
void setNonGC (bool Value)
 
bool isGlobalObjCRef () const
 
void setGlobalObjCRef (bool Value)
 
bool isThreadLocalRef () const
 
void setThreadLocalRef (bool Value)
 
ARCPreciseLifetime_t isARCPreciseLifetime () const
 
void setARCPreciseLifetime (ARCPreciseLifetime_t value)
 
bool isNontemporal () const
 
void setNontemporal (bool Value)
 
bool isObjCWeak () const
 
bool isObjCStrong () const
 
bool isVolatile () const
 
ExprgetBaseIvarExp () const
 
void setBaseIvarExp (Expr *V)
 
TBAAAccessInfo getTBAAInfo () const
 
void setTBAAInfo (TBAAAccessInfo Info)
 
const QualifiersgetQuals () const
 
QualifiersgetQuals ()
 
LangAS getAddressSpace () const
 
CharUnits getAlignment () const
 
void setAlignment (CharUnits A)
 
LValueBaseInfo getBaseInfo () const
 
void setBaseInfo (LValueBaseInfo Info)
 
llvm::Value * getPointer (CodeGenFunction &CGF) const
 
Address getAddress (CodeGenFunction &CGF) const
 
void setAddress (Address address)
 
Address getVectorAddress () const
 
llvm::Value * getVectorPointer () const
 
llvm::Value * getVectorIdx () const
 
Address getMatrixAddress () const
 
llvm::Value * getMatrixPointer () const
 
llvm::Value * getMatrixIdx () const
 
Address getExtVectorAddress () const
 
llvm::Value * getExtVectorPointer () const
 
llvm::Constant * getExtVectorElts () const
 
Address getBitFieldAddress () const
 
llvm::Value * getBitFieldPointer () const
 
const CGBitFieldInfogetBitFieldInfo () const
 
llvm::Value * getGlobalReg () const
 
RValue asAggregateRValue (CodeGenFunction &CGF) const
 

Static Public Member Functions

static LValue MakeAddr (Address address, QualType type, ASTContext &Context, LValueBaseInfo BaseInfo, TBAAAccessInfo TBAAInfo)
 
static LValue MakeVectorElt (Address vecAddress, llvm::Value *Idx, QualType type, LValueBaseInfo BaseInfo, TBAAAccessInfo TBAAInfo)
 
static LValue MakeExtVectorElt (Address vecAddress, llvm::Constant *Elts, QualType type, LValueBaseInfo BaseInfo, TBAAAccessInfo TBAAInfo)
 
static LValue MakeBitfield (Address Addr, const CGBitFieldInfo &Info, QualType type, LValueBaseInfo BaseInfo, TBAAAccessInfo TBAAInfo)
 Create a new object to represent a bit-field access. More...
 
static LValue MakeGlobalReg (llvm::Value *V, CharUnits alignment, QualType type)
 
static LValue MakeMatrixElt (Address matAddress, llvm::Value *Idx, QualType type, LValueBaseInfo BaseInfo, TBAAAccessInfo TBAAInfo)
 

Detailed Description

LValue - This represents an lvalue references.

Because C/C++ allow bitfields, this is not a simple LLVM pointer, it may be a pointer plus a bitrange.

Definition at line 171 of file CGValue.h.

Member Function Documentation

◆ asAggregateRValue()

RValue clang::CodeGen::LValue::asAggregateRValue ( CodeGenFunction CGF) const
inline

◆ getAddress()

Address clang::CodeGen::LValue::getAddress ( CodeGenFunction CGF) const
inline

Definition at line 341 of file CGValue.h.

References getAlignment(), and getPointer().

Referenced by clang::CodeGen::ReductionCodeGen::adjustPrivateAddress(), clang::CodeGen::CGOpenMPRuntimeGPU::adjustTargetSpecificDataForLambdas(), asAggregateRValue(), clang::CodeGen::CodeGenFunction::callCStructCopyAssignmentOperator(), clang::CodeGen::CodeGenFunction::callCStructCopyConstructor(), clang::CodeGen::CodeGenFunction::callCStructDefaultConstructor(), clang::CodeGen::CodeGenFunction::callCStructDestructor(), clang::CodeGen::CodeGenFunction::callCStructMoveAssignmentOperator(), clang::CodeGen::CodeGenFunction::callCStructMoveConstructor(), clang::CodeGen::CGOpenMPRuntime::checkAndEmitLastprivateConditional(), clang::CodeGen::CallArg::copyInto(), clang::CodeGen::CodeGenFunction::defaultInitNonTrivialCStructVar(), drillIntoBlockVariable(), clang::CodeGen::CodeGenFunction::EmitAggregateCopy(), clang::CodeGen::CodeGenFunction::EmitARCStoreStrong(), clang::CodeGen::CodeGenFunction::EmitArraySubscriptExpr(), clang::CodeGen::CodeGenFunction::EmitArrayToPointerDecay(), clang::CodeGen::CodeGenFunction::EmitAtomicCompareExchange(), clang::CodeGen::CodeGenFunction::EmitAtomicStore(), clang::CodeGen::CodeGenFunction::EmitCastLValue(), clang::CodeGen::CodeGenFunction::EmitCXXMemberPointerCallExpr(), clang::CodeGen::CodeGenFunction::EmitCXXPseudoDestructorExpr(), clang::CodeGen::CodeGenFunction::EmitDeclRefLValue(), clang::CodeGen::CGOpenMPRuntime::emitDestroyClause(), emitGlobalToListCopyFunction(), emitGlobalToListReduceFunction(), clang::CodeGen::CodeGenFunction::EmitInitializerForField(), clang::CodeGen::CGOpenMPRuntime::emitLastprivateConditionalInit(), emitListToGlobalCopyFunction(), emitListToGlobalReduceFunction(), clang::CodeGen::CodeGenFunction::EmitLoadOfLValue(), EmitLoadOfMatrixLValue(), clang::CodeGen::CodeGenFunction::EmitLoadOfReference(), clang::CodeGen::CodeGenFunction::EmitLoadOfScalar(), clang::CodeGen::CodeGenFunction::EmitLValue(), clang::CodeGen::CodeGenFunction::EmitLValueForField(), clang::CodeGen::CodeGenFunction::EmitMaterializeTemporaryExpr(), EmitMemberInitializer(), clang::CodeGen::CodeGenFunction::EmitMSVAListRef(), clang::CodeGen::CodeGenFunction::EmitObjCIsaExpr(), clang::CodeGen::CodeGenFunction::EmitObjCMessageExpr(), emitOMPArraySectionBase(), clang::CodeGen::CodeGenFunction::EmitOMPArraySectionExpr(), emitOMPAtomicCompareExpr(), clang::CodeGen::CodeGenFunction::EmitOMPFirstprivateClause(), clang::CodeGen::CodeGenFunction::EmitOMPReductionClauseInit(), emitOutlinedFunctionPrologue(), clang::CodeGen::CodeGenFunction::EmitParmDecl(), clang::CodeGen::CodeGenFunction::EmitPointerToDataMemberBinaryExpr(), clang::CodeGen::CodeGenFunction::EmitPointerWithAlignment(), emitPrivatesInit(), clang::CodeGen::CodeGenFunction::EmitScalarInit(), clang::CodeGen::CodeGenFunction::EmitSimpleOMPExecutableDirective(), EmitStoreOfMatrixScalar(), clang::CodeGen::CodeGenFunction::EmitStoreOfScalar(), clang::CodeGen::CGOpenMPRuntime::emitTaskLoopCall(), clang::CodeGen::CGOpenMPRuntime::emitTaskReductionInit(), EmitTypeidFromVTable(), clang::CodeGen::CodeGenFunction::EmitUnaryOpLValue(), clang::CodeGen::CodeGenFunction::EmitVAListRef(), emitWriteback(), emitWritebackArg(), clang::CodeGen::AggValueSlot::forLValue(), clang::CodeGen::CodeGenFunction::generateObjCGetterBody(), clang::CodeGen::CodeGenFunction::generateObjCSetterBody(), getPointerAndSize(), clang::CodeGen::CallArg::getRValue(), loadToBegin(), clang::CodeGen::CodeGenFunction::StartFunction(), tryEmitARCCopyWeakInit(), and tryEmitARCRetainLoadOfScalar().

◆ getAddressSpace()

LangAS clang::CodeGen::LValue::getAddressSpace ( ) const
inline

◆ getAlignment()

CharUnits clang::CodeGen::LValue::getAlignment ( ) const
inline

◆ getBaseInfo()

LValueBaseInfo clang::CodeGen::LValue::getBaseInfo ( ) const
inline

◆ getBaseIvarExp()

Expr* clang::CodeGen::LValue::getBaseIvarExp ( ) const
inline

Definition at line 319 of file CGValue.h.

◆ getBitFieldAddress()

Address clang::CodeGen::LValue::getBitFieldAddress ( ) const
inline

◆ getBitFieldInfo()

const CGBitFieldInfo& clang::CodeGen::LValue::getBitFieldInfo ( ) const
inline

◆ getBitFieldPointer()

llvm::Value* clang::CodeGen::LValue::getBitFieldPointer ( ) const
inline

Definition at line 393 of file CGValue.h.

References isBitField(), and V.

Referenced by getBitFieldAddress().

◆ getExtVectorAddress()

Address clang::CodeGen::LValue::getExtVectorAddress ( ) const
inline

◆ getExtVectorElts()

llvm::Constant* clang::CodeGen::LValue::getExtVectorElts ( ) const
inline

◆ getExtVectorPointer()

llvm::Value* clang::CodeGen::LValue::getExtVectorPointer ( ) const
inline

Definition at line 380 of file CGValue.h.

References isExtVectorElt(), and V.

Referenced by getExtVectorAddress().

◆ getGlobalReg()

llvm::Value* clang::CodeGen::LValue::getGlobalReg ( ) const
inline

◆ getMatrixAddress()

Address clang::CodeGen::LValue::getMatrixAddress ( ) const
inline

Definition at line 364 of file CGValue.h.

References getAlignment(), and getMatrixPointer().

◆ getMatrixIdx()

llvm::Value* clang::CodeGen::LValue::getMatrixIdx ( ) const
inline

◆ getMatrixPointer()

llvm::Value* clang::CodeGen::LValue::getMatrixPointer ( ) const
inline

Definition at line 367 of file CGValue.h.

References isMatrixElt(), and V.

Referenced by getMatrixAddress().

◆ getObjCLifetime()

Qualifiers::ObjCLifetime clang::CodeGen::LValue::getObjCLifetime ( ) const
inline

◆ getPointer()

llvm::Value* clang::CodeGen::LValue::getPointer ( CodeGenFunction CGF) const
inline

◆ getQuals() [1/2]

Qualifiers& clang::CodeGen::LValue::getQuals ( )
inline

Definition at line 326 of file CGValue.h.

◆ getQuals() [2/2]

const Qualifiers& clang::CodeGen::LValue::getQuals ( ) const
inline

◆ getTBAAInfo()

TBAAAccessInfo clang::CodeGen::LValue::getTBAAInfo ( ) const
inline

◆ getType()

QualType clang::CodeGen::LValue::getType ( ) const
inline

Definition at line 278 of file CGValue.h.

Referenced by clang::CodeGen::CodeGenFunction::callCStructCopyAssignmentOperator(), clang::CodeGen::CodeGenFunction::callCStructCopyConstructor(), clang::CodeGen::CodeGenFunction::callCStructDefaultConstructor(), clang::CodeGen::CodeGenFunction::callCStructDestructor(), clang::CodeGen::CodeGenFunction::callCStructMoveAssignmentOperator(), clang::CodeGen::CodeGenFunction::callCStructMoveConstructor(), clang::CodeGen::CodeGenFunction::defaultInitNonTrivialCStructVar(), clang::CodeGen::CodeGenFunction::EmitAggregateCopyCtor(), clang::CodeGen::CodeGenFunction::EmitARCStoreStrong(), clang::CodeGen::CodeGenFunction::EmitArraySubscriptExpr(), clang::CodeGen::CodeGenFunction::EmitAtomicLoad(), clang::CodeGen::CodeGenFunction::EmitAtomicStore(), EmitAtomicUpdateValue(), clang::CodeGen::CodeGenFunction::EmitDeclRefLValue(), clang::CodeGen::CodeGenFunction::EmitExtVectorElementLValue(), emitGlobalToListCopyFunction(), clang::CodeGen::CGOpenMPRuntime::emitLastprivateConditionalFinalUpdate(), emitListToGlobalCopyFunction(), clang::CodeGen::CodeGenFunction::EmitLoadOfBitfieldLValue(), clang::CodeGen::CodeGenFunction::EmitLoadOfExtVectorElementLValue(), clang::CodeGen::CodeGenFunction::EmitLoadOfGlobalRegLValue(), clang::CodeGen::CodeGenFunction::EmitLoadOfLValue(), EmitLoadOfMatrixLValue(), clang::CodeGen::CodeGenFunction::EmitLoadOfReference(), clang::CodeGen::CodeGenFunction::EmitLoadOfReferenceLValue(), clang::CodeGen::CodeGenFunction::EmitLoadOfScalar(), clang::CodeGen::CodeGenFunction::EmitLValue(), clang::CodeGen::CodeGenFunction::EmitLValueForField(), clang::CodeGen::CodeGenFunction::EmitNullabilityCheck(), clang::CodeGen::CodeGenFunction::emitOMPSimpleStore(), emitOutlinedFunctionPrologue(), emitPreserveStructAccess(), emitPrivatesInit(), clang::CodeGen::CodeGenFunction::EmitScalarInit(), EmitStoreOfMatrixScalar(), clang::CodeGen::CodeGenFunction::EmitStoreOfScalar(), clang::CodeGen::CodeGenFunction::EmitStoreThroughBitfieldLValue(), clang::CodeGen::CodeGenFunction::EmitStoreThroughExtVectorComponentLValue(), clang::CodeGen::CodeGenFunction::EmitStoreThroughGlobalRegLValue(), clang::CodeGen::CodeGenFunction::EmitStoreThroughLValue(), clang::CodeGen::CGOpenMPRuntime::emitTaskReductionInit(), clang::CodeGen::CodeGenFunction::EmitUnaryOpLValue(), loadToBegin(), and clang::CodeGen::CodeGenFunction::LValueIsSuitableForInlineAtomic().

◆ getVectorAddress()

Address clang::CodeGen::LValue::getVectorAddress ( ) const
inline

◆ getVectorIdx()

llvm::Value* clang::CodeGen::LValue::getVectorIdx ( ) const
inline

◆ getVectorPointer()

llvm::Value* clang::CodeGen::LValue::getVectorPointer ( ) const
inline

Definition at line 355 of file CGValue.h.

References isVectorElt(), and V.

Referenced by getVectorAddress().

◆ getVRQualifiers()

unsigned clang::CodeGen::LValue::getVRQualifiers ( ) const
inline

◆ isARCPreciseLifetime()

ARCPreciseLifetime_t clang::CodeGen::LValue::isARCPreciseLifetime ( ) const
inline

◆ isBitField()

bool clang::CodeGen::LValue::isBitField ( ) const
inline

◆ isExtVectorElt()

bool clang::CodeGen::LValue::isExtVectorElt ( ) const
inline

◆ isGlobalObjCRef()

bool clang::CodeGen::LValue::isGlobalObjCRef ( ) const
inline

Definition at line 293 of file CGValue.h.

Referenced by setObjCGCLValueClass().

◆ isGlobalReg()

bool clang::CodeGen::LValue::isGlobalReg ( ) const
inline

◆ isMatrixElt()

bool clang::CodeGen::LValue::isMatrixElt ( ) const
inline

◆ isNonGC()

bool clang::CodeGen::LValue::isNonGC ( ) const
inline

Definition at line 290 of file CGValue.h.

◆ isNontemporal()

bool clang::CodeGen::LValue::isNontemporal ( ) const
inline

◆ isObjCArray()

bool clang::CodeGen::LValue::isObjCArray ( ) const
inline

Definition at line 287 of file CGValue.h.

Referenced by setObjCGCLValueClass().

◆ isObjCIvar()

bool clang::CodeGen::LValue::isObjCIvar ( ) const
inline

Definition at line 284 of file CGValue.h.

Referenced by setObjCGCLValueClass().

◆ isObjCStrong()

bool clang::CodeGen::LValue::isObjCStrong ( ) const
inline

Definition at line 311 of file CGValue.h.

References clang::Qualifiers::getObjCGCAttr(), and clang::Qualifiers::Strong.

Referenced by EmitDeclInit().

◆ isObjCWeak()

bool clang::CodeGen::LValue::isObjCWeak ( ) const
inline

◆ isRestrictQualified()

bool clang::CodeGen::LValue::isRestrictQualified ( ) const
inline

Definition at line 273 of file CGValue.h.

References clang::Qualifiers::hasRestrict().

◆ isSimple()

bool clang::CodeGen::LValue::isSimple ( ) const
inline

◆ isThreadLocalRef()

bool clang::CodeGen::LValue::isThreadLocalRef ( ) const
inline

Definition at line 296 of file CGValue.h.

◆ isVectorElt()

bool clang::CodeGen::LValue::isVectorElt ( ) const
inline

◆ isVolatile()

bool clang::CodeGen::LValue::isVolatile ( ) const
inline

◆ isVolatileQualified()

bool clang::CodeGen::LValue::isVolatileQualified ( ) const
inline

◆ MakeAddr()

static LValue clang::CodeGen::LValue::MakeAddr ( Address  address,
QualType  type,
ASTContext Context,
LValueBaseInfo  BaseInfo,
TBAAAccessInfo  TBAAInfo 
)
inlinestatic

◆ MakeBitfield()

static LValue clang::CodeGen::LValue::MakeBitfield ( Address  Addr,
const CGBitFieldInfo Info,
QualType  type,
LValueBaseInfo  BaseInfo,
TBAAAccessInfo  TBAAInfo 
)
inlinestatic

Create a new object to represent a bit-field access.

Parameters
Addr- The base address of the bit-field sequence this bit-field refers to.
Info- The information describing how to perform the bit-field access.

Definition at line 448 of file CGValue.h.

References BitFieldInfo, clang::CodeGen::Address::getAlignment(), clang::CodeGen::Address::getElementType(), and clang::CodeGen::Address::getPointer().

Referenced by EmitAtomicUpdateValue(), clang::CodeGen::CodeGenFunction::EmitLValueForField(), and clang::CodeGen::CGObjCRuntime::EmitValueForIvarAtOffset().

◆ MakeExtVectorElt()

static LValue clang::CodeGen::LValue::MakeExtVectorElt ( Address  vecAddress,
llvm::Constant *  Elts,
QualType  type,
LValueBaseInfo  BaseInfo,
TBAAAccessInfo  TBAAInfo 
)
inlinestatic

◆ MakeGlobalReg()

static LValue clang::CodeGen::LValue::MakeGlobalReg ( llvm::Value *  V,
CharUnits  alignment,
QualType  type 
)
inlinestatic

Definition at line 461 of file CGValue.h.

References clang::CodeGen::Decl, and V.

◆ MakeMatrixElt()

static LValue clang::CodeGen::LValue::MakeMatrixElt ( Address  matAddress,
llvm::Value *  Idx,
QualType  type,
LValueBaseInfo  BaseInfo,
TBAAAccessInfo  TBAAInfo 
)
inlinestatic

◆ MakeVectorElt()

static LValue clang::CodeGen::LValue::MakeVectorElt ( Address  vecAddress,
llvm::Value *  Idx,
QualType  type,
LValueBaseInfo  BaseInfo,
TBAAAccessInfo  TBAAInfo 
)
inlinestatic

◆ setAddress()

void clang::CodeGen::LValue::setAddress ( Address  address)
inline

◆ setAlignment()

void clang::CodeGen::LValue::setAlignment ( CharUnits  A)
inline

Definition at line 331 of file CGValue.h.

References clang::CharUnits::getQuantity().

◆ setARCPreciseLifetime()

void clang::CodeGen::LValue::setARCPreciseLifetime ( ARCPreciseLifetime_t  value)
inline

◆ setBaseInfo()

void clang::CodeGen::LValue::setBaseInfo ( LValueBaseInfo  Info)
inline

Definition at line 334 of file CGValue.h.

◆ setBaseIvarExp()

void clang::CodeGen::LValue::setBaseIvarExp ( Expr V)
inline

Definition at line 320 of file CGValue.h.

References V.

Referenced by setObjCGCLValueClass().

◆ setGlobalObjCRef()

void clang::CodeGen::LValue::setGlobalObjCRef ( bool  Value)
inline

Definition at line 294 of file CGValue.h.

Referenced by setObjCGCLValueClass().

◆ setNonGC()

void clang::CodeGen::LValue::setNonGC ( bool  Value)
inline

◆ setNontemporal()

void clang::CodeGen::LValue::setNontemporal ( bool  Value)
inline

◆ setObjCArray()

void clang::CodeGen::LValue::setObjCArray ( bool  Value)
inline

Definition at line 288 of file CGValue.h.

Referenced by setObjCGCLValueClass().

◆ setObjCIvar()

void clang::CodeGen::LValue::setObjCIvar ( bool  Value)
inline

Definition at line 285 of file CGValue.h.

Referenced by setObjCGCLValueClass().

◆ setTBAAInfo()

void clang::CodeGen::LValue::setTBAAInfo ( TBAAAccessInfo  Info)
inline

Definition at line 323 of file CGValue.h.

◆ setThreadLocalRef()

void clang::CodeGen::LValue::setThreadLocalRef ( bool  Value)
inline

Definition at line 297 of file CGValue.h.

Referenced by setObjCGCLValueClass().

Member Data Documentation

◆ BitFieldInfo

const CGBitFieldInfo* clang::CodeGen::LValue::BitFieldInfo

Definition at line 192 of file CGValue.h.

Referenced by getBitFieldInfo(), and MakeBitfield().

◆ VectorElts

llvm::Constant* clang::CodeGen::LValue::VectorElts

Definition at line 189 of file CGValue.h.

Referenced by getExtVectorElts(), and MakeExtVectorElt().

◆ VectorIdx

llvm::Value* clang::CodeGen::LValue::VectorIdx

Definition at line 186 of file CGValue.h.

Referenced by getMatrixIdx(), getVectorIdx(), MakeMatrixElt(), and MakeVectorElt().


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