clang
3.9.0
|
#include "CGBlocks.h"
#include "CGCXXABI.h"
#include "CGDebugInfo.h"
#include "CGRecordLayout.h"
#include "CodeGenFunction.h"
#include "clang/AST/CXXInheritance.h"
#include "clang/AST/DeclTemplate.h"
#include "clang/AST/EvaluatedExprVisitor.h"
#include "clang/AST/RecordLayout.h"
#include "clang/AST/StmtCXX.h"
#include "clang/Basic/TargetBuiltins.h"
#include "clang/CodeGen/CGFunctionInfo.h"
#include "clang/Frontend/CodeGenOptions.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/IR/Metadata.h"
#include "llvm/Transforms/Utils/SanitizerStats.h"
Go to the source code of this file.
|
static |
Definition at line 225 of file CGClass.cpp.
References clang::CharUnits::alignmentAtOffset(), clang::CodeGen::CodeGenFunction::Builder, clang::CodeGen::CodeGenFunction::CGM, clang::CodeGen::CGBuilderTy::CreateBitCast(), clang::CodeGen::Address::getAlignment(), clang::CodeGen::Address::getPointer(), clang::CharUnits::getQuantity(), clang::CodeGen::CodeGenModule::getVBaseAlignment(), clang::CodeGen::CodeGenTypeCache::Int8PtrTy, clang::CharUnits::isZero(), and clang::CodeGen::CodeGenTypeCache::PtrDiffTy.
Referenced by clang::CodeGen::CodeGenFunction::EmitVTableAssumptionLoad(), clang::CodeGen::CodeGenFunction::GetAddressOfBaseClass(), and clang::CodeGen::CodeGenFunction::InitializeVTablePointer().
|
static |
Definition at line 514 of file CGClass.cpp.
Referenced by EmitBaseInitializer().
|
static |
Definition at line 2077 of file CGClass.cpp.
References clang::TargetCXXABI::areArgsDestroyedLeftToRightInCallee(), clang::CodeGen::CodeGenTypes::arrangeCXXConstructorCall(), clang::CodeGen::CodeGenFunction::CGM, clang::TargetInfo::getCXXABI(), clang::CodeGen::CodeGenFunction::getTarget(), clang::CodeGen::CodeGenModule::getTypes(), clang::FunctionDecl::isVariadic(), P, clang::FunctionDecl::parameters(), and clang::CodeGen::CGFunctionInfo::usesInAlloca().
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXConstructorCall().
|
static |
CanSkipVTablePointerInitialization - Check whether we need to initialize any vtable pointers before calling this destructor.
Definition at line 1484 of file CGClass.cpp.
References FieldHasTrivialDestructorBody(), clang::RecordDecl::fields(), clang::CodeGen::CodeGenFunction::getContext(), clang::CXXMethodDecl::getParent(), clang::FunctionDecl::hasTrivialBody(), and clang::CXXRecordDecl::isDynamicClass().
Referenced by clang::CodeGen::CodeGenFunction::EmitDestructorBody().
|
static |
Definition at line 565 of file CGClass.cpp.
References clang::CharUnits::alignmentOfArrayElement(), clang::CodeGen::CodeGenFunction::Builder, clang::CodeGen::CodeGenFunction::createBasicBlock(), clang::CodeGen::CGBuilderTy::CreateLoad(), clang::CodeGen::CGBuilderTy::CreateStore(), clang::CodeGen::AggValueSlot::DoesNotNeedGCBarriers, clang::CodeGen::CodeGenFunction::EmitAggExpr(), clang::CodeGen::CodeGenFunction::EmitBlock(), clang::CodeGen::CodeGenFunction::EmitBranch(), clang::CodeGen::CodeGenFunction::EmitComplexExprIntoLValue(), clang::CodeGen::CodeGenFunction::EmitScalarInit(), clang::CodeGen::AggValueSlot::forLValue(), clang::CodeGen::CodeGenFunction::GetAddrOfLocalVar(), clang::CodeGen::LValue::getAlignment(), clang::ASTContext::getAsConstantArrayType(), clang::CodeGen::CodeGenFunction::getContext(), clang::CodeGen::Address::getElementType(), clang::ArrayType::getElementType(), clang::CodeGen::CodeGenFunction::getEvaluationKind(), clang::CodeGen::LValue::getPointer(), clang::ConstantArrayType::getSize(), clang::ASTContext::getTypeSizeInChars(), clang::CodeGen::AggValueSlot::IsDestructed, clang::CodeGen::AggValueSlot::IsNotAliased, clang::CodeGen::Address::isValid(), Next, clang::CodeGen::LValue::setAddress(), clang::CodeGen::TEK_Aggregate, clang::CodeGen::TEK_Complex, and clang::CodeGen::TEK_Scalar.
Referenced by clang::CodeGen::CodeGenFunction::EmitInitializerForField().
|
static |
Definition at line 520 of file CGClass.cpp.
References BaseInitializerUsesThis(), clang::CodeGen::CodeGenFunction::CGM, clang::Ctor_Base, clang::CodeGen::AggValueSlot::DoesNotNeedGCBarriers, clang::CodeGen::EHCleanup, clang::CodeGen::CodeGenFunction::EHStack, clang::CodeGen::CodeGenFunction::EmitAggExpr(), clang::CodeGen::AggValueSlot::forAddr(), clang::CodeGen::CodeGenFunction::GetAddressOfDirectBaseInCompleteClass(), clang::Type::getAs(), clang::CXXCtorInitializer::getBaseClass(), clang::CodeGen::CodeGenFunction::getContext(), clang::CXXCtorInitializer::getInit(), clang::CodeGen::CodeGenModule::getLangOpts(), clang::CXXRecordDecl::hasTrivialDestructor(), clang::CodeGen::CodeGenFunction::InitializeVTablePointers(), clang::CXXCtorInitializer::isBaseInitializer(), clang::CXXCtorInitializer::isBaseVirtual(), clang::CodeGen::AggValueSlot::IsDestructed, clang::CodeGen::AggValueSlot::IsNotAliased, and clang::CodeGen::CodeGenFunction::LoadCXXThisAddress().
Referenced by clang::CodeGen::CodeGenFunction::EmitCtorPrologue().
|
static |
Definition at line 681 of file CGClass.cpp.
References clang::IndirectFieldDecl::chain(), clang::CodeGen::CodeGenFunction::EmitLValueForFieldInitialization(), clang::CXXCtorInitializer::getAnyMember(), clang::CXXCtorInitializer::getIndirectMember(), I, and clang::CXXCtorInitializer::isIndirectMemberInitializer().
Referenced by EmitMemberInitializer().
|
static |
Definition at line 695 of file CGClass.cpp.
References clang::CodeGen::CodeGenFunction::Builder, clang::CodeGen::CodeGenFunction::CGM, clang::CodeGen::CGBuilderTy::CreateLoad(), clang::CodeGen::CodeGenFunction::EmitAggregateCopy(), clang::CodeGen::CodeGenFunction::EmitInitializerForField(), EmitLValueForAnyFieldInitialization(), clang::CodeGen::CodeGenFunction::EmitLValueForFieldInitialization(), clang::CodeGen::LValue::getAddress(), clang::CodeGen::CodeGenFunction::GetAddrOfLocalVar(), clang::CXXCtorInitializer::getAnyMember(), clang::CXXCtorInitializer::getArrayIndices(), clang::ASTContext::getAsConstantArrayType(), clang::ASTContext::getBaseElementType(), clang::CXXConstructExpr::getConstructor(), clang::CodeGen::CodeGenFunction::getContext(), clang::CodeGen::CodeGenModule::getCXXABI(), clang::CXXCtorInitializer::getInit(), clang::CXXCtorInitializer::getNumArrayIndices(), clang::CXXCtorInitializer::getSourceLocation(), clang::CodeGen::CGCXXABI::getSrcArgforCopyCtor(), clang::ASTContext::getTypeDeclType(), clang::CXXCtorInitializer::isAnyMemberInitializer(), clang::CXXConstructorDecl::isCopyOrMoveConstructor(), clang::FunctionDecl::isDefaulted(), clang::QualType::isDestructedType(), isMemcpyEquivalentSpecialMember(), clang::QualType::isPODType(), clang::CodeGen::LValue::isVolatileQualified(), clang::CodeGen::CodeGenFunction::LoadCXXThis(), clang::CodeGen::CodeGenFunction::MakeNaturalAlignAddrLValue(), clang::CodeGen::CodeGenFunction::needsEHCleanup(), and clang::CodeGen::CodeGenFunction::pushEHDestroy().
|
static |
Definition at line 1464 of file CGClass.cpp.
References clang::Type::getAs(), clang::ASTContext::getBaseElementType(), clang::RecordType::getDecl(), clang::ValueDecl::getType(), HasTrivialDestructorBody(), clang::RecordDecl::isAnonymousStructOrUnion(), and clang::TagDecl::isUnion().
Referenced by CanSkipVTablePointerInitialization(), and HasTrivialDestructorBody().
|
static |
Definition at line 1421 of file CGClass.cpp.
References clang::CXXRecordDecl::bases(), FieldHasTrivialDestructorBody(), clang::RecordDecl::fields(), clang::CXXRecordDecl::getDestructor(), clang::FunctionDecl::hasTrivialBody(), clang::CXXRecordDecl::hasTrivialDestructor(), I, and clang::CXXRecordDecl::vbases().
Referenced by FieldHasTrivialDestructorBody().
|
static |
Checks whether the given constructor is a valid subject for the complete-to-base constructor delegation optimization, i.e.
emitting the complete constructor as a simple call to the base constructor.
Definition at line 807 of file CGClass.cpp.
References clang::Type::getAs(), clang::CXXRecordDecl::getNumVBases(), clang::CXXMethodDecl::getParent(), clang::ValueDecl::getType(), and clang::CXXConstructorDecl::isDelegatingConstructor().
Referenced by clang::CodeGen::CodeGenFunction::EmitConstructorBody().
|
static |
Definition at line 1343 of file CGClass.cpp.
References clang::Type::getAs(), and clang::CXXCtorInitializer::getBaseClass().
Referenced by clang::CodeGen::CodeGenFunction::EmitCtorPrologue().
|
static |
Definition at line 664 of file CGClass.cpp.
References clang::CXXMethodDecl::getParent(), clang::CXXMethodDecl::isCopyAssignmentOperator(), clang::FunctionDecl::isDefaulted(), clang::CXXMethodDecl::isMoveAssignmentOperator(), clang::FunctionDecl::isTrivial(), clang::TagDecl::isUnion(), and clang::RecordDecl::mayInsertExtraPadding().
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXConstructorCall(), and EmitMemberInitializer().
|
static |
Definition at line 2587 of file CGClass.cpp.
References clang::CXXRecordDecl::bases_begin(), clang::RecordDecl::field_empty(), clang::Type::getAsCXXRecordDecl(), clang::CXXRecordDecl::getNumBases(), clang::CXXRecordDecl::getNumVBases(), clang::CXXBaseSpecifier::getType(), clang::CXXMethodDecl::isVirtual(), and clang::CXXRecordDecl::methods().
Referenced by clang::CodeGen::CodeGenFunction::EmitVTablePtrCheckForCall(), and clang::CodeGen::CodeGenFunction::EmitVTablePtrCheckForCast().
Definition at line 2810 of file CGClass.cpp.
References E.
Referenced by clang::CodeGen::CodeGenFunction::CanDevirtualizeMemberFunctionCall().