clang API Documentation
#include "CodeGenFunction.h"
#include "CGCXXABI.h"
#include "CGObjCRuntime.h"
#include "CGOpenMPRuntime.h"
#include "clang/Frontend/CodeGenOptions.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/Support/Path.h"
Go to the source code of this file.
Functions | |
static void | EmitDeclInit (CodeGenFunction &CGF, const VarDecl &D, llvm::Constant *DeclPtr) |
static void | EmitDeclDestroy (CodeGenFunction &CGF, const VarDecl &D, llvm::Constant *addr) |
static void | EmitDeclInvariant (CodeGenFunction &CGF, const VarDecl &D, llvm::Constant *Addr) |
static void EmitDeclDestroy | ( | CodeGenFunction & | CGF, |
const VarDecl & | D, | ||
llvm::Constant * | addr | ||
) | [static] |
Emit code to cause the destruction of the given variable with static storage duration.
Definition at line 66 of file CGDeclCXX.cpp.
References clang::CodeGen::CodeGenFunction::CGM, clang::CodeGen::Complete, clang::CodeGen::CodeGenTypes::ConvertType(), clang::QualType::DK_cxx_destructor, clang::QualType::DK_none, clang::QualType::DK_objc_strong_lifetime, clang::QualType::DK_objc_weak_lifetime, clang::CodeGen::CodeGenFunction::generateDestroyHelper(), clang::CodeGen::CodeGenModule::getAddrOfCXXStructor(), clang::Type::getAsCXXRecordDecl(), clang::CodeGen::CodeGenModule::getCXXABI(), clang::CodeGen::CodeGenFunction::getDestroyer(), clang::CXXRecordDecl::getDestructor(), clang::VarDecl::getTLSKind(), clang::ValueDecl::getType(), clang::CodeGen::CodeGenFunction::getTypes(), clang::CXXRecordDecl::hasTrivialDestructor(), clang::CodeGen::CodeGenTypeCache::Int8PtrTy, clang::QualType::isDestructedType(), clang::CodeGen::CodeGenFunction::needsEHCleanup(), clang::CodeGen::CGCXXABI::registerGlobalDtor(), and clang::ast_matchers::type.
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXGlobalVarDeclInit().
static void EmitDeclInit | ( | CodeGenFunction & | CGF, |
const VarDecl & | D, | ||
llvm::Constant * | DeclPtr | ||
) | [static] |
Definition at line 26 of file CGDeclCXX.cpp.
References clang::CodeGen::CodeGenFunction::CGM, Context, clang::CodeGen::AggValueSlot::DoesNotNeedGCBarriers, clang::CodeGen::CodeGenFunction::EmitAggExpr(), clang::CodeGen::CodeGenFunction::EmitComplexExprIntoLValue(), clang::CodeGen::CGObjCRuntime::EmitObjCGlobalAssign(), clang::CodeGen::CGObjCRuntime::EmitObjCWeakAssign(), clang::CodeGen::CodeGenFunction::EmitScalarExpr(), clang::CodeGen::CodeGenFunction::EmitScalarInit(), clang::CodeGen::AggValueSlot::forLValue(), clang::CodeGen::CodeGenFunction::getContext(), clang::CodeGen::CodeGenFunction::getEvaluationKind(), clang::VarDecl::getInit(), clang::CodeGen::CodeGenModule::getObjCRuntime(), clang::VarDecl::getTLSKind(), clang::ValueDecl::getType(), clang::VarDecl::hasGlobalStorage(), clang::CodeGen::AggValueSlot::IsDestructed, clang::CodeGen::AggValueSlot::IsNotAliased, clang::CodeGen::LValue::isObjCStrong(), clang::CodeGen::LValue::isObjCWeak(), clang::Type::isReferenceType(), clang::CodeGen::CodeGenFunction::MakeAddrLValue(), clang::CodeGen::TEK_Aggregate, clang::CodeGen::TEK_Complex, clang::CodeGen::TEK_Scalar, and clang::ast_matchers::type.
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXGlobalVarDeclInit().
static void EmitDeclInvariant | ( | CodeGenFunction & | CGF, |
const VarDecl & | D, | ||
llvm::Constant * | Addr | ||
) | [static] |
Emit code to cause the variable at the given address to be considered as constant from this point onwards.
Definition at line 117 of file CGDeclCXX.cpp.
References clang::CodeGen::CodeGenFunction::Builder, clang::CodeGen::CodeGenFunction::CGM, clang::CodeGen::CodeGenModule::getCodeGenOpts(), clang::CodeGen::CodeGenFunction::getContext(), clang::CodeGen::CodeGenModule::getIntrinsic(), clang::CharUnits::getQuantity(), clang::ValueDecl::getType(), clang::ASTContext::getTypeSizeInChars(), clang::CodeGen::CodeGenTypeCache::Int64Ty, and clang::CodeGen::CodeGenTypeCache::Int8PtrTy.
Referenced by clang::CodeGen::CodeGenFunction::EmitCXXGlobalVarDeclInit().