clang
8.0.0
|
The scope used to remap some variables as private in the OpenMP loop body (or other captured region emitted without outlining), and to restore old vars back on exit. More...
#include "/work/www-prereleases/8.0.0/rc3/docsbuild/llvm.src/tools/clang/lib/CodeGen/CodeGenFunction.h"
Public Member Functions | |
OMPPrivateScope (CodeGenFunction &CGF) | |
Enter a new OpenMP private scope. More... | |
bool | addPrivate (const VarDecl *LocalVD, const llvm::function_ref< Address()> PrivateGen) |
Registers LocalVD variable as a private and apply PrivateGen function for it to generate corresponding private variable. More... | |
bool | Privatize () |
Privatizes local variables previously registered as private. More... | |
void | ForceCleanup () |
~OMPPrivateScope () | |
Exit scope - all the mapped variables are restored. More... | |
bool | isGlobalVarCaptured (const VarDecl *VD) const |
Checks if the global variable is captured in current function. More... | |
![]() | |
RunCleanupsScope (CodeGenFunction &CGF) | |
Enter a new cleanup scope. More... | |
~RunCleanupsScope () | |
Exit this cleanup scope, emitting any accumulated cleanups. More... | |
bool | requiresCleanups () const |
Determine whether this scope requires any cleanups. More... | |
void | ForceCleanup (std::initializer_list< llvm::Value **> ValuesToReload={}) |
Force the emission of cleanups now, instead of waiting until this object is destroyed. More... | |
Additional Inherited Members | |
![]() | |
bool | PerformCleanup |
CodeGenFunction & | CGF |
The scope used to remap some variables as private in the OpenMP loop body (or other captured region emitted without outlining), and to restore old vars back on exit.
Definition at line 894 of file CodeGenFunction.h.
|
inlineexplicit |
Enter a new OpenMP private scope.
Definition at line 901 of file CodeGenFunction.h.
|
inline |
Exit scope - all the mapped variables are restored.
Definition at line 930 of file CodeGenFunction.h.
|
inline |
Registers LocalVD
variable as a private and apply PrivateGen
function for it to generate corresponding private variable.
PrivateGen
returns an address of the generated private variable.
Definition at line 908 of file CodeGenFunction.h.
References clang::CodeGen::CodeGenFunction::OMPMapVars::setVarAddr().
Referenced by clang::CodeGen::CodeGenFunction::EmitOMPCopy(), clang::CodeGen::CodeGenFunction::EmitOMPFirstprivateClause(), clang::CodeGen::CodeGenFunction::EmitOMPLastprivateClauseInit(), clang::CodeGen::CodeGenFunction::EmitOMPLinearClause(), clang::CodeGen::CodeGenFunction::EmitOMPPrivateClause(), clang::CodeGen::CodeGenFunction::EmitOMPPrivateLoopCounters(), clang::CodeGen::CodeGenFunction::EmitOMPReductionClauseInit(), clang::CodeGen::CodeGenFunction::EmitOMPTargetTaskBasedDirective(), clang::CodeGen::CodeGenFunction::EmitOMPUseDevicePtrClause(), emitPrivatesInit(), emitReduceCombFunction(), clang::CodeGen::CodeGenFunction::EmitSimpleOMPExecutableDirective(), and mapParam().
|
inline |
Definition at line 924 of file CodeGenFunction.h.
References clang::CodeGen::CodeGenFunction::OMPMapVars::restore().
|
inline |
Checks if the global variable is captured in current function.
Definition at line 936 of file CodeGenFunction.h.
References clang::VarDecl::getCanonicalDecl(), and clang::VarDecl::isLocalVarDeclOrParm().
|
inline |
Privatizes local variables previously registered as private.
Registration is separate from the actual privatization to allow initializers use values of the original variables, not the private one. This is important, for example, if the private variable is a class variable initialized by a constructor that references other private variables. But at initialization original variables must be used, not private copies.
Definition at line 922 of file CodeGenFunction.h.
References clang::CodeGen::CodeGenFunction::OMPMapVars::apply().
Referenced by clang::CodeGen::CodeGenFunction::EmitOMPCopy(), clang::CodeGen::CodeGenFunction::EmitOMPDistributeLoop(), emitOMPSimdRegion(), clang::CodeGen::CodeGenFunction::EmitOMPTargetTaskBasedDirective(), clang::CodeGen::CodeGenFunction::EmitOMPWorksharingLoop(), emitPreCond(), emitPrivatesInit(), emitReduceCombFunction(), clang::CodeGen::CodeGenFunction::EmitSimpleOMPExecutableDirective(), and emitTargetRegion().