class OMPTaskLoopDirective

Declaration

class OMPTaskLoopDirective : public OMPLoopDirective { /* full declaration omitted */ };

Description

This represents '#pragma omp taskloop' directive. In this example directive '#pragma omp taskloop' has clauses 'private' with the variables 'a' and 'b', 'grainsize' with expression 'val' and 'num_tasks' with expression 'num'.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3659

Inherits from: OMPLoopDirective

Member Variables

private bool HasCancel = false
true if the construct has inner cancel directive.

Inherited from OMPLoopBasedDirective:

protected NumAssociatedLoops = 0

Inherited from OMPExecutableDirective:

protected Data = nullptr

Inherited from Stmt:

protected

Method Overview

  • public static clang::OMPTaskLoopDirective * Create(const clang::ASTContext & C, clang::SourceLocation StartLoc, clang::SourceLocation EndLoc, unsigned int CollapsedNum, ArrayRef<clang::OMPClause *> Clauses, clang::Stmt * AssociatedStmt, const clang::OMPLoopBasedDirective::HelperExprs & Exprs, bool HasCancel)
  • public static clang::OMPTaskLoopDirective * CreateEmpty(const clang::ASTContext & C, unsigned int NumClauses, unsigned int CollapsedNum, clang::Stmt::EmptyShell)
  • private OMPTaskLoopDirective(clang::SourceLocation StartLoc, clang::SourceLocation EndLoc, unsigned int CollapsedNum)
  • private OMPTaskLoopDirective(unsigned int CollapsedNum)
  • public static bool classof(const clang::Stmt * T)
  • public bool hasCancel() const
  • private void setHasCancel(bool Has)

Inherited from OMPLoopDirective:

Inherited from OMPLoopBasedDirective:

Inherited from OMPExecutableDirective:

Inherited from Stmt:

Methods

static clang::OMPTaskLoopDirective* Create(
    const clang::ASTContext& C,
    clang::SourceLocation StartLoc,
    clang::SourceLocation EndLoc,
    unsigned int CollapsedNum,
    ArrayRef<clang::OMPClause*> Clauses,
    clang::Stmt* AssociatedStmt,
    const clang::OMPLoopBasedDirective::
        HelperExprs& Exprs,
    bool HasCancel)

Description

Creates directive with a list of \a Clauses.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3700

Parameters

const clang::ASTContext& C
AST context.
clang::SourceLocation StartLoc
Starting location of the directive kind.
clang::SourceLocation EndLoc
Ending Location of the directive.
unsigned int CollapsedNum
Number of collapsed loops.
ArrayRef<clang::OMPClause*> Clauses
List of clauses.
clang::Stmt* AssociatedStmt
Statement, associated with the directive.
const clang::OMPLoopBasedDirective::HelperExprs& Exprs
Helper expressions for CodeGen.
bool HasCancel
true if this directive has inner cancel directive.

static clang::OMPTaskLoopDirective* CreateEmpty(
    const clang::ASTContext& C,
    unsigned int NumClauses,
    unsigned int CollapsedNum,
    clang::Stmt::EmptyShell)

Description

Creates an empty directive with the place for \a NumClauses clauses.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3711

Parameters

const clang::ASTContext& C
AST context.
unsigned int NumClauses
Number of clauses.
unsigned int CollapsedNum
Number of collapsed nested loops.
clang::Stmt::EmptyShell

OMPTaskLoopDirective(
    clang::SourceLocation StartLoc,
    clang::SourceLocation EndLoc,
    unsigned int CollapsedNum)

Description

Build directive with the given start and end location.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3671

Parameters

clang::SourceLocation StartLoc
Starting location of the directive kind.
clang::SourceLocation EndLoc
Ending location of the directive.
unsigned int CollapsedNum
Number of collapsed nested loops.

OMPTaskLoopDirective(unsigned int CollapsedNum)

Description

Build an empty directive.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3680

Parameters

unsigned int CollapsedNum
Number of collapsed nested loops.

static bool classof(const clang::Stmt* T)

Declared at: clang/include/clang/AST/StmtOpenMP.h:3718

Parameters

const clang::Stmt* T

bool hasCancel() const

Description

Return true if current directive has inner cancel directive.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3716

void setHasCancel(bool Has)

Description

Set cancel state.

Declared at: clang/include/clang/AST/StmtOpenMP.h:3685

Parameters

bool Has