clang  6.0.0svn
Public Types | Public Member Functions | Static Public Member Functions | Friends | List of all members
OMPUseDevicePtrClause Class Referencefinal

This represents clause 'use_device_ptr' in the '#pragma omp ...' directives. More...

#include "clang/AST/OpenMPClause.h"

Inheritance diagram for OMPUseDevicePtrClause:
Inheritance graph
[legend]
Collaboration diagram for OMPUseDevicePtrClause:
Collaboration graph
[legend]

Public Types

using private_copies_iterator = MutableArrayRef< Expr * >::iterator
 
using private_copies_const_iterator = ArrayRef< const Expr * >::iterator
 
using private_copies_range = llvm::iterator_range< private_copies_iterator >
 
using private_copies_const_range = llvm::iterator_range< private_copies_const_iterator >
 
using inits_iterator = MutableArrayRef< Expr * >::iterator
 
using inits_const_iterator = ArrayRef< const Expr * >::iterator
 
using inits_range = llvm::iterator_range< inits_iterator >
 
using inits_const_range = llvm::iterator_range< inits_const_iterator >
 
- Public Types inherited from OMPMappableExprListClause< OMPUseDevicePtrClause >
using const_component_lists_range = llvm::iterator_range< const_component_lists_iterator >
 
using const_all_decls_iterator = ArrayRef< ValueDecl *>::iterator
 Iterators to access all the declarations, number of lists, list sizes, and components. More...
 
using const_all_decls_range = llvm::iterator_range< const_all_decls_iterator >
 
using const_all_num_lists_iterator = ArrayRef< unsigned >::iterator
 
using const_all_num_lists_range = llvm::iterator_range< const_all_num_lists_iterator >
 
using const_all_lists_sizes_iterator = ArrayRef< unsigned >::iterator
 
using const_all_lists_sizes_range = llvm::iterator_range< const_all_lists_sizes_iterator >
 
using const_all_components_iterator = ArrayRef< MappableComponent >::iterator
 
using const_all_components_range = llvm::iterator_range< const_all_components_iterator >
 
- Public Types inherited from OMPClauseMappableExprCommon
using MappableExprComponentList = SmallVector< MappableComponent, 8 >
 
using MappableExprComponentListRef = ArrayRef< MappableComponent >
 
using MappableExprComponentLists = SmallVector< MappableExprComponentList, 8 >
 
using MappableExprComponentListsRef = ArrayRef< MappableExprComponentList >
 

Public Member Functions

private_copies_range private_copies ()
 
private_copies_const_range private_copies () const
 
inits_range inits ()
 
inits_const_range inits () const
 
child_range children ()
 
- Public Member Functions inherited from OMPMappableExprListClause< OMPUseDevicePtrClause >
unsigned getUniqueDeclarationsNum () const
 Return the number of unique base declarations in this clause. More...
 
unsigned getTotalComponentListNum () const
 Return the number of lists derived from the clause expressions. More...
 
unsigned getTotalComponentsNum () const
 Return the total number of components in all lists derived from the clause. More...
 
const_component_lists_iterator component_lists_begin () const
 Iterators for all component lists. More...
 
const_component_lists_iterator component_lists_end () const
 
const_component_lists_range component_lists () const
 
const_component_lists_iterator decl_component_lists_begin (const ValueDecl *VD) const
 Iterators for component lists associated with the provided declaration. More...
 
const_component_lists_iterator decl_component_lists_end () const
 
const_component_lists_range decl_component_lists (const ValueDecl *VD) const
 
const_all_decls_range all_decls () const
 
const_all_num_lists_range all_num_lists () const
 
const_all_lists_sizes_range all_lists_sizes () const
 
const_all_components_range all_components () const
 

Static Public Member Functions

static OMPUseDevicePtrClauseCreate (const ASTContext &C, SourceLocation StartLoc, SourceLocation LParenLoc, SourceLocation EndLoc, ArrayRef< Expr *> Vars, ArrayRef< Expr *> PrivateVars, ArrayRef< Expr *> Inits, ArrayRef< ValueDecl *> Declarations, MappableExprComponentListsRef ComponentLists)
 Creates clause with a list of variables Vars. More...
 
static OMPUseDevicePtrClauseCreateEmpty (const ASTContext &C, unsigned NumVars, unsigned NumUniqueDeclarations, unsigned NumComponentLists, unsigned NumComponents)
 Creates an empty clause with the place for NumVars variables. More...
 
static bool classof (const OMPClause *T)
 

Friends

class OMPClauseReader
 

Additional Inherited Members

- Protected Member Functions inherited from OMPMappableExprListClause< OMPUseDevicePtrClause >
 OMPMappableExprListClause (OpenMPClauseKind K, SourceLocation StartLoc, SourceLocation LParenLoc, SourceLocation EndLoc, unsigned NumVars, unsigned NumUniqueDeclarations, unsigned NumComponentLists, unsigned NumComponents)
 Build a clause for NumUniqueDeclarations declarations, NumComponentLists total component lists, and NumComponents total components. More...
 
MutableArrayRef< ValueDecl *> getUniqueDeclsRef ()
 Get the unique declarations that are in the trailing objects of the class. More...
 
ArrayRef< ValueDecl *> getUniqueDeclsRef () const
 Get the unique declarations that are in the trailing objects of the class. More...
 
void setUniqueDecls (ArrayRef< ValueDecl * > UDs)
 Set the unique declarations that are in the trailing objects of the class. More...
 
MutableArrayRef< unsigned > getDeclNumListsRef ()
 Get the number of lists per declaration that are in the trailing objects of the class. More...
 
ArrayRef< unsigned > getDeclNumListsRef () const
 Get the number of lists per declaration that are in the trailing objects of the class. More...
 
void setDeclNumLists (ArrayRef< unsigned > DNLs)
 Set the number of lists per declaration that are in the trailing objects of the class. More...
 
MutableArrayRef< unsigned > getComponentListSizesRef ()
 Get the cumulative component lists sizes that are in the trailing objects of the class. More...
 
ArrayRef< unsigned > getComponentListSizesRef () const
 Get the cumulative component lists sizes that are in the trailing objects of the class. More...
 
void setComponentListSizes (ArrayRef< unsigned > CLSs)
 Set the cumulative component lists sizes that are in the trailing objects of the class. More...
 
MutableArrayRef< MappableComponentgetComponentsRef ()
 Get the components that are in the trailing objects of the class. More...
 
ArrayRef< MappableComponentgetComponentsRef () const
 Get the components that are in the trailing objects of the class. More...
 
void setComponents (ArrayRef< MappableComponent > Components, ArrayRef< unsigned > CLSs)
 Set the components that are in the trailing objects of the class. More...
 
void setClauseInfo (ArrayRef< ValueDecl * > Declarations, MappableExprComponentListsRef ComponentLists)
 Fill the clause information from the list of declarations and associated component lists. More...
 
- Static Protected Member Functions inherited from OMPClauseMappableExprCommon
static unsigned getComponentsTotalNumber (MappableExprComponentListsRef ComponentLists)
 
static unsigned getUniqueDeclarationsTotalNumber (ArrayRef< ValueDecl *> Declarations)
 

Detailed Description

This represents clause 'use_device_ptr' in the '#pragma omp ...' directives.

#pragma omp target data use_device_ptr(a,b)

In this example directive '#pragma omp target data' has clause 'use_device_ptr' with the variables 'a' and 'b'.

Definition at line 4729 of file OpenMPClause.h.

Member Typedef Documentation

◆ inits_const_iterator

using OMPUseDevicePtrClause::inits_const_iterator = ArrayRef<const Expr *>::iterator

Definition at line 4864 of file OpenMPClause.h.

◆ inits_const_range

Definition at line 4866 of file OpenMPClause.h.

◆ inits_iterator

using OMPUseDevicePtrClause::inits_iterator = MutableArrayRef<Expr *>::iterator

Definition at line 4863 of file OpenMPClause.h.

◆ inits_range

using OMPUseDevicePtrClause::inits_range = llvm::iterator_range<inits_iterator>

Definition at line 4865 of file OpenMPClause.h.

◆ private_copies_const_iterator

using OMPUseDevicePtrClause::private_copies_const_iterator = ArrayRef<const Expr *>::iterator

Definition at line 4848 of file OpenMPClause.h.

◆ private_copies_const_range

Definition at line 4851 of file OpenMPClause.h.

◆ private_copies_iterator

using OMPUseDevicePtrClause::private_copies_iterator = MutableArrayRef<Expr *>::iterator

Definition at line 4847 of file OpenMPClause.h.

◆ private_copies_range

Definition at line 4849 of file OpenMPClause.h.

Member Function Documentation

◆ children()

child_range OMPUseDevicePtrClause::children ( )
inline

Definition at line 4876 of file OpenMPClause.h.

◆ classof()

static bool OMPUseDevicePtrClause::classof ( const OMPClause T)
inlinestatic

Definition at line 4881 of file OpenMPClause.h.

◆ Create()

OMPUseDevicePtrClause * OMPUseDevicePtrClause::Create ( const ASTContext C,
SourceLocation  StartLoc,
SourceLocation  LParenLoc,
SourceLocation  EndLoc,
ArrayRef< Expr *>  Vars,
ArrayRef< Expr *>  PrivateVars,
ArrayRef< Expr *>  Inits,
ArrayRef< ValueDecl *>  Declarations,
MappableExprComponentListsRef  ComponentLists 
)
static

Creates clause with a list of variables Vars.

Parameters
CAST context.
StartLocStarting location of the clause.
EndLocEnding location of the clause.
VarsThe original expression used in the clause.
PrivateVarsExpressions referring to private copies.
InitsExpressions referring to private copy initializers.
DeclarationsDeclarations used in the clause.
ComponentListsComponent lists used in the clause.

Definition at line 881 of file OpenMPClause.cpp.

References clang::ASTContext::Allocate(), and OMPMappableExprListClause< T >::setClauseInfo().

Referenced by clang::Sema::ActOnOpenMPUseDevicePtrClause().

◆ CreateEmpty()

OMPUseDevicePtrClause * OMPUseDevicePtrClause::CreateEmpty ( const ASTContext C,
unsigned  NumVars,
unsigned  NumUniqueDeclarations,
unsigned  NumComponentLists,
unsigned  NumComponents 
)
static

Creates an empty clause with the place for NumVars variables.

Parameters
CAST context.
NumVarsNumber of expressions listed in the clause.
NumUniqueDeclarationsNumber of unique base declarations in this clause.
NumComponentListsNumber of unique base declarations in this clause.
NumComponentsTotal number of expression components in the clause.

Definition at line 919 of file OpenMPClause.cpp.

References clang::ASTContext::Allocate().

◆ inits() [1/2]

inits_range OMPUseDevicePtrClause::inits ( )
inline

Definition at line 4868 of file OpenMPClause.h.

References clang::getInits().

Referenced by clang::OMPClauseWriter::VisitOMPClauseWithPostUpdate().

◆ inits() [2/2]

inits_const_range OMPUseDevicePtrClause::inits ( ) const
inline

Definition at line 4872 of file OpenMPClause.h.

References clang::getInits().

◆ private_copies() [1/2]

private_copies_range OMPUseDevicePtrClause::private_copies ( )
inline

◆ private_copies() [2/2]

private_copies_const_range OMPUseDevicePtrClause::private_copies ( ) const
inline

Definition at line 4858 of file OpenMPClause.h.

Friends And Related Function Documentation

◆ OMPClauseReader

friend class OMPClauseReader
friend

Definition at line 4734 of file OpenMPClause.h.


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