class OMPCancelDirective

Declaration

class OMPCancelDirective : public OMPExecutableDirective { /* full declaration omitted */ };

Description

This represents '#pragma omp cancel' directive. In this example a cancel is created for innermost 'for' region.

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

Inherits from: OMPExecutableDirective

Member Variables

private clang::OpenMPDirectiveKind CancelRegion = llvm::omp::OMPD_unknown

Inherited from OMPExecutableDirective:

protected Data = nullptr

Inherited from Stmt:

protected

Method Overview

  • public static clang::OMPCancelDirective * Create(const clang::ASTContext & C, clang::SourceLocation StartLoc, clang::SourceLocation EndLoc, ArrayRef<clang::OMPClause *> Clauses, clang::OpenMPDirectiveKind CancelRegion)
  • public static clang::OMPCancelDirective * CreateEmpty(const clang::ASTContext & C, unsigned int NumClauses, clang::Stmt::EmptyShell)
  • private OMPCancelDirective(clang::SourceLocation StartLoc, clang::SourceLocation EndLoc)
  • private OMPCancelDirective()
  • public static bool classof(const clang::Stmt * T)
  • public clang::OpenMPDirectiveKind getCancelRegion() const
  • private void setCancelRegion(clang::OpenMPDirectiveKind CR)

Inherited from OMPExecutableDirective:

Inherited from Stmt:

Methods

static clang::OMPCancelDirective* Create(
    const clang::ASTContext& C,
    clang::SourceLocation StartLoc,
    clang::SourceLocation EndLoc,
    ArrayRef<clang::OMPClause*> Clauses,
    clang::OpenMPDirectiveKind CancelRegion)

Description

Creates directive.

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

Parameters

const clang::ASTContext& C
AST context.
clang::SourceLocation StartLoc
Starting location of the directive kind.
clang::SourceLocation EndLoc
Ending Location of the directive.
ArrayRef<clang::OMPClause*> Clauses
List of clauses.
clang::OpenMPDirectiveKind CancelRegion

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

Description

Creates an empty directive.

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

Parameters

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

OMPCancelDirective(clang::SourceLocation StartLoc,
                   clang::SourceLocation EndLoc)

Description

Build directive with the given start and end location.

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

Parameters

clang::SourceLocation StartLoc
Starting location of the directive kind.
clang::SourceLocation EndLoc
Ending location of the directive.

OMPCancelDirective()

Description

Build an empty directive.

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

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

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

Parameters

const clang::Stmt* T

clang::OpenMPDirectiveKind getCancelRegion() const

Description

Get cancellation region for the current cancellation point.

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

void setCancelRegion(
    clang::OpenMPDirectiveKind CR)

Description

Set cancel region for current cancellation point.

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

Parameters

clang::OpenMPDirectiveKind CR
Cancellation region.