clang 24.0.0git
clang::OMPDepthClause Class Referencefinal

This represents the 'depth' clause on the '#pragma omp flatten' (and '#pragma omp fuse') loop-transformation directives. More...

#include "clang/AST/OpenMPClause.h"

Inheritance diagram for clang::OMPDepthClause:
[legend]

Public Member Functions

 OMPDepthClause (SourceLocation StartLoc, SourceLocation LParenLoc, SourceLocation EndLoc, Expr *Depth)
 Build an AST node for a 'depth' clause.
SourceLocation getLParenLoc () const
 Returns the location of '('.
Expr * getDepth () const
 Returns the depth expression or nullptr if not set.
child_range children ()
const_child_range children () const
child_range used_children ()
const_child_range used_children () const
Public Member Functions inherited from clang::OMPClause
SourceLocation getBeginLoc () const
 Returns the starting location of the clause.
SourceLocation getEndLoc () const
 Returns the ending location of the clause.
void setLocStart (SourceLocation Loc)
 Sets the starting location of the clause.
void setLocEnd (SourceLocation Loc)
 Sets the ending location of the clause.
OpenMPClauseKind getClauseKind () const
 Returns kind of OpenMP clause (private, shared, reduction, etc.).
bool isImplicit () const
child_range children ()
const_child_range children () const
child_range used_children ()
 Get the iterator range for the expressions used in the clauses.
const_child_range used_children () const

Static Public Member Functions

static bool classof (const OMPClause *T)
Static Public Member Functions inherited from clang::OMPClause
static bool classof (const OMPClause *)

Friends

class OMPClauseReader

Additional Inherited Members

Public Types inherited from clang::OMPClause
using child_iterator = StmtIterator
using const_child_iterator = ConstStmtIterator
using child_range = llvm::iterator_range<child_iterator>
using const_child_range = llvm::iterator_range<const_child_iterator>
Protected Member Functions inherited from clang::OMPClause
 OMPClause (OpenMPClauseKind K, SourceLocation StartLoc, SourceLocation EndLoc)

Detailed Description

This represents the 'depth' clause on the '#pragma omp flatten' (and '#pragma omp fuse') loop-transformation directives.

#pragma omp flatten depth(3)

In this example the 'flatten' directive has a 'depth' clause whose argument '3' specifies how many perfectly nested loops are combined into one. The argument must be a positive integer constant expression that evaluates to at most the loop nest depth of the associated loop nest.

Definition at line 1480 of file OpenMPClause.h.

Constructor & Destructor Documentation

◆ OMPDepthClause()

clang::OMPDepthClause::OMPDepthClause ( SourceLocation StartLoc,
SourceLocation LParenLoc,
SourceLocation EndLoc,
Expr * Depth )
inline

Build an AST node for a 'depth' clause.

Parameters
StartLocLocation of the 'depth' identifier.
LParenLocLocation of '('.
EndLocLocation of ')'.
DepthThe depth expression.

Definition at line 1506 of file OpenMPClause.h.

References clang::OMPClause::OMPClause().

Member Function Documentation

◆ children() [1/2]

child_range clang::OMPDepthClause::children ( )
inline

Definition at line 1517 of file OpenMPClause.h.

◆ children() [2/2]

const_child_range clang::OMPDepthClause::children ( ) const
inline

Definition at line 1518 of file OpenMPClause.h.

◆ classof()

bool clang::OMPDepthClause::classof ( const OMPClause * T)
inlinestatic

Definition at line 1529 of file OpenMPClause.h.

References clang::OMPClause::OMPClause(), and clang::T.

◆ getDepth()

Expr * clang::OMPDepthClause::getDepth ( ) const
inline

Returns the depth expression or nullptr if not set.

Definition at line 1515 of file OpenMPClause.h.

◆ getLParenLoc()

SourceLocation clang::OMPDepthClause::getLParenLoc ( ) const
inline

Returns the location of '('.

Definition at line 1512 of file OpenMPClause.h.

◆ used_children() [1/2]

child_range clang::OMPDepthClause::used_children ( )
inline

Definition at line 1522 of file OpenMPClause.h.

◆ used_children() [2/2]

const_child_range clang::OMPDepthClause::used_children ( ) const
inline

Definition at line 1525 of file OpenMPClause.h.

◆ OMPClauseReader

friend class OMPClauseReader
friend

Definition at line 1481 of file OpenMPClause.h.

References clang::OMPClause::OMPClause(), and OMPClauseReader.

Referenced by OMPClauseReader.


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