clang  7.0.0svn
Classes | Protected Member Functions | Protected Attributes | List of all members
clang::CodeGen::CGOpenMPRuntime Class Reference

#include "/opt/doxygen-docs/src/llvm/tools/clang/lib/CodeGen/CGOpenMPRuntime.h"

Inheritance diagram for clang::CodeGen::CGOpenMPRuntime:
Inheritance graph
Collaboration diagram for clang::CodeGen::CGOpenMPRuntime:
Collaboration graph

Protected Member Functions

virtual void createOffloadEntry (llvm::Constant *ID, llvm::Constant *Addr, uint64_t Size, int32_t Flags=0)
 Creates offloading entry for the provided entry ID ID, address Addr, size Size, and flags Flags. More...
virtual void emitTargetOutlinedFunctionHelper (const OMPExecutableDirective &D, StringRef ParentName, llvm::Function *&OutlinedFn, llvm::Constant *&OutlinedFnID, bool IsOffloadEntry, const RegionCodeGenTy &CodeGen)
 Helper to emit outlined function for 'target' directive. More...
void emitOMPIfClause (CodeGenFunction &CGF, const Expr *Cond, const RegionCodeGenTy &ThenGen, const RegionCodeGenTy &ElseGen)
 Emits code for OpenMP 'if' clause using specified CodeGen function. More...
llvm::ValueemitUpdateLocation (CodeGenFunction &CGF, SourceLocation Loc, unsigned Flags=0)
 Emits object of ident_t type with info for source location. More...
llvm::TypegetIdentTyPointerTy ()
 Returns pointer to ident_t type. More...
llvm::ValuegetThreadID (CodeGenFunction &CGF, SourceLocation Loc)
 Gets thread id value for the current thread. More...
virtual StringRef getOutlinedHelperName () const
 Get the function name of an outlined region. More...
void emitCall (CodeGenFunction &CGF, llvm::Value *Callee, ArrayRef< llvm::Value *> Args=llvm::None, SourceLocation Loc=SourceLocation()) const
 Emits Callee function call with arguments Args with location Loc. More...

Protected Attributes


Detailed Description

Definition at line 199 of file CGOpenMPRuntime.h.

Member Function Documentation

◆ createOffloadEntry()

void CGOpenMPRuntime::createOffloadEntry ( llvm::Constant *  ID,
llvm::Constant *  Addr,
uint64_t  Size,
int32_t  Flags = 0 

◆ emitCall()

void CGOpenMPRuntime::emitCall ( CodeGenFunction CGF,
llvm::Value Callee,
ArrayRef< llvm::Value *>  Args = llvm::None,
SourceLocation  Loc = SourceLocation() 
) const

◆ emitOMPIfClause()

void CGOpenMPRuntime::emitOMPIfClause ( CodeGenFunction CGF,
const Expr Cond,
const RegionCodeGenTy ThenGen,
const RegionCodeGenTy ElseGen 

◆ emitTargetOutlinedFunctionHelper()

void CGOpenMPRuntime::emitTargetOutlinedFunctionHelper ( const OMPExecutableDirective D,
StringRef  ParentName,
llvm::Function *&  OutlinedFn,
llvm::Constant *&  OutlinedFnID,
bool  IsOffloadEntry,
const RegionCodeGenTy CodeGen 

Helper to emit outlined function for 'target' directive.

DDirective to emit.
ParentNameName of the function that encloses the target region.
OutlinedFnOutlined function value to be defined by this call.
OutlinedFnIDOutlined function ID value to be defined by this call.
IsOffloadEntryTrue if the outlined function is an offload entry.
CodeGenLambda codegen specific to an accelerator device. An outlined function may not be an entry if, e.g. the if clause always evaluates to false.

Definition at line 5866 of file CGOpenMPRuntime.cpp.

References clang::ExternalLinkage, clang::CodeGen::CodeGenFunction::GenerateOpenMPCapturedStmtFunction(), clang::OMPExecutableDirective::getCapturedStmt(), clang::CodeGen::CodeGenModule::getContext(), clang::CodeGen::CodeGenModule::getLangOpts(), clang::OMPExecutableDirective::getLocStart(), clang::CodeGen::CodeGenModule::getModule(), getTargetEntryUniqueInfo(), clang::CodeGen::CodeGenTypeCache::Int8PtrTy, clang::CodeGen::CodeGenTypeCache::Int8Ty, Line, clang::CodeGen::OffloadEntriesInfoManager, and clang::CodeGen::OffloadEntriesInfoManagerTy::registerTargetRegionEntryInfo().

Referenced by getTargetEntryUniqueInfo().

◆ emitUpdateLocation()

llvm::Value * CGOpenMPRuntime::emitUpdateLocation ( CodeGenFunction CGF,
SourceLocation  Loc,
unsigned  Flags = 0 

◆ getIdentTyPointerTy()

llvm::Type * CGOpenMPRuntime::getIdentTyPointerTy ( )

Returns pointer to ident_t type.

Definition at line 1541 of file CGOpenMPRuntime.cpp.

Referenced by clang::CodeGen::createRuntimeFunction().

◆ getOutlinedHelperName()

virtual StringRef clang::CodeGen::CGOpenMPRuntime::getOutlinedHelperName ( ) const

Get the function name of an outlined region.

Reimplemented in clang::CodeGen::CGOpenMPRuntimeNVPTX.

Definition at line 251 of file CGOpenMPRuntime.h.

Referenced by emitParallelOrTeamsOutlinedFunction().

◆ getThreadID()

llvm::Value * CGOpenMPRuntime::getThreadID ( CodeGenFunction CGF,
SourceLocation  Loc 

Member Data Documentation


CodeGenModule& clang::CodeGen::CGOpenMPRuntime::CGM

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