LLVM 17.0.0git
Public Member Functions | Public Attributes | List of all members
llvm::OpenMPIRBuilderConfig Class Reference

Captures attributes that affect generating LLVM-IR using the OpenMPIRBuilder and related classes. More...

#include "llvm/Frontend/OpenMP/OMPIRBuilder.h"

Public Member Functions

 OpenMPIRBuilderConfig ()
 
 OpenMPIRBuilderConfig (bool IsEmbedded, bool IsTargetCodegen, bool HasRequiresUnifiedSharedMemory, bool OpenMPOffloadMandatory)
 
bool isEmbedded () const
 
bool isTargetCodegen () const
 
bool hasRequiresUnifiedSharedMemory () const
 
bool openMPOffloadMandatory () const
 
StringRef firstSeparator () const
 
StringRef separator () const
 
void setIsEmbedded (bool Value)
 
void setIsTargetCodegen (bool Value)
 
void setHasRequiresUnifiedSharedMemory (bool Value)
 
void setFirstSeparator (StringRef FS)
 
void setSeparator (StringRef S)
 

Public Attributes

std::optional< boolIsEmbedded
 Flag for specifying if the compilation is done for embedded device code or host code.
 
std::optional< boolIsTargetCodegen
 Flag for specifying if the compilation is done for an offloading target, like GPU.
 
std::optional< boolHasRequiresUnifiedSharedMemory
 Flag for specifying weather a requires unified_shared_memory directive is present or not.
 
std::optional< boolOpenMPOffloadMandatory
 
std::optional< StringRefFirstSeparator
 First separator used between the initial two parts of a name.
 
std::optional< StringRefSeparator
 Separator used between all of the rest consecutive parts of s name.
 

Detailed Description

Captures attributes that affect generating LLVM-IR using the OpenMPIRBuilder and related classes.

Note that not all attributes are required for all classes or functions. In some use cases the configuration is not necessary at all, because because the only functions that are called are ones that are not dependent on the configuration.

Definition at line 83 of file OMPIRBuilder.h.

Constructor & Destructor Documentation

◆ OpenMPIRBuilderConfig() [1/2]

llvm::OpenMPIRBuilderConfig::OpenMPIRBuilderConfig ( )
inline

Definition at line 105 of file OMPIRBuilder.h.

◆ OpenMPIRBuilderConfig() [2/2]

llvm::OpenMPIRBuilderConfig::OpenMPIRBuilderConfig ( bool  IsEmbedded,
bool  IsTargetCodegen,
bool  HasRequiresUnifiedSharedMemory,
bool  OpenMPOffloadMandatory 
)
inline

Definition at line 106 of file OMPIRBuilder.h.

Member Function Documentation

◆ firstSeparator()

StringRef llvm::OpenMPIRBuilderConfig::firstSeparator ( ) const
inline

Definition at line 137 of file OMPIRBuilder.h.

References FirstSeparator, and isTargetCodegen().

Referenced by llvm::OpenMPIRBuilder::createPlatformSpecificName().

◆ hasRequiresUnifiedSharedMemory()

bool llvm::OpenMPIRBuilderConfig::hasRequiresUnifiedSharedMemory ( ) const
inline

◆ isEmbedded()

bool llvm::OpenMPIRBuilderConfig::isEmbedded ( ) const
inline

◆ isTargetCodegen()

bool llvm::OpenMPIRBuilderConfig::isTargetCodegen ( ) const
inline

Definition at line 119 of file OMPIRBuilder.h.

References assert(), and IsTargetCodegen.

Referenced by llvm::OpenMPIRBuilder::createOffloadEntry(), firstSeparator(), and separator().

◆ openMPOffloadMandatory()

bool llvm::OpenMPIRBuilderConfig::openMPOffloadMandatory ( ) const
inline

Definition at line 130 of file OMPIRBuilder.h.

References assert(), and OpenMPOffloadMandatory.

Referenced by llvm::OpenMPIRBuilder::emitTargetRegionFunction().

◆ separator()

StringRef llvm::OpenMPIRBuilderConfig::separator ( ) const
inline

Definition at line 147 of file OMPIRBuilder.h.

References isTargetCodegen(), and Separator.

Referenced by llvm::OpenMPIRBuilder::createPlatformSpecificName().

◆ setFirstSeparator()

void llvm::OpenMPIRBuilderConfig::setFirstSeparator ( StringRef  FS)
inline

Definition at line 160 of file OMPIRBuilder.h.

References FirstSeparator.

◆ setHasRequiresUnifiedSharedMemory()

void llvm::OpenMPIRBuilderConfig::setHasRequiresUnifiedSharedMemory ( bool  Value)
inline

Definition at line 157 of file OMPIRBuilder.h.

References HasRequiresUnifiedSharedMemory.

◆ setIsEmbedded()

void llvm::OpenMPIRBuilderConfig::setIsEmbedded ( bool  Value)
inline

Definition at line 155 of file OMPIRBuilder.h.

References IsEmbedded.

◆ setIsTargetCodegen()

void llvm::OpenMPIRBuilderConfig::setIsTargetCodegen ( bool  Value)
inline

Definition at line 156 of file OMPIRBuilder.h.

References IsTargetCodegen.

◆ setSeparator()

void llvm::OpenMPIRBuilderConfig::setSeparator ( StringRef  S)
inline

Definition at line 161 of file OMPIRBuilder.h.

References Separator.

Member Data Documentation

◆ FirstSeparator

std::optional<StringRef> llvm::OpenMPIRBuilderConfig::FirstSeparator

First separator used between the initial two parts of a name.

Definition at line 101 of file OMPIRBuilder.h.

Referenced by firstSeparator(), and setFirstSeparator().

◆ HasRequiresUnifiedSharedMemory

std::optional<bool> llvm::OpenMPIRBuilderConfig::HasRequiresUnifiedSharedMemory

Flag for specifying weather a requires unified_shared_memory directive is present or not.

Definition at line 95 of file OMPIRBuilder.h.

Referenced by hasRequiresUnifiedSharedMemory(), and setHasRequiresUnifiedSharedMemory().

◆ IsEmbedded

std::optional<bool> llvm::OpenMPIRBuilderConfig::IsEmbedded

Flag for specifying if the compilation is done for embedded device code or host code.

Definition at line 87 of file OMPIRBuilder.h.

Referenced by isEmbedded(), and setIsEmbedded().

◆ IsTargetCodegen

std::optional<bool> llvm::OpenMPIRBuilderConfig::IsTargetCodegen

Flag for specifying if the compilation is done for an offloading target, like GPU.

Definition at line 91 of file OMPIRBuilder.h.

Referenced by isTargetCodegen(), and setIsTargetCodegen().

◆ OpenMPOffloadMandatory

std::optional<bool> llvm::OpenMPIRBuilderConfig::OpenMPOffloadMandatory

Definition at line 98 of file OMPIRBuilder.h.

Referenced by openMPOffloadMandatory().

◆ Separator

std::optional<StringRef> llvm::OpenMPIRBuilderConfig::Separator

Separator used between all of the rest consecutive parts of s name.

Definition at line 103 of file OMPIRBuilder.h.

Referenced by separator(), and setSeparator().


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