class OMPSafelenClause

Declaration

class OMPSafelenClause : public OMPClause { /* full declaration omitted */ };

Description

This represents 'safelen' clause in the '#pragma omp ...' directive. In this example directive '#pragma omp simd' has clause 'safelen' with single expression '4'. If the safelen clause is used then no two iterations executed concurrently with SIMD instructions can have a greater distance in the logical iteration space than its value. The parameter of the safelen clause must be a constant positive integer expression.

Declared at: clang/include/clang/AST/OpenMPClause.h:752

Inherits from: OMPClause

Member Variables

private clang::SourceLocation LParenLoc
Location of '('.
private clang::Stmt* Safelen = nullptr
Safe iteration space distance.

Method Overview

Inherited from OMPClause:

Methods

OMPSafelenClause(clang::Expr* Len,
                 clang::SourceLocation StartLoc,
                 clang::SourceLocation LParenLoc,
                 clang::SourceLocation EndLoc)

Description

Build 'safelen' clause.

Declared at: clang/include/clang/AST/OpenMPClause.h:770

Parameters

clang::Expr* Len
Expression associated with this clause.
clang::SourceLocation StartLoc
Starting location of the clause.
clang::SourceLocation LParenLoc
clang::SourceLocation EndLoc
Ending location of the clause.

OMPSafelenClause()

Description

Build an empty clause.

Declared at: clang/include/clang/AST/OpenMPClause.h:776

clang::OMPClause::child_range children()

Declared at: clang/include/clang/AST/OpenMPClause.h:789

clang::OMPClause::const_child_range children()
    const

Declared at: clang/include/clang/AST/OpenMPClause.h:791

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

Declared at: clang/include/clang/AST/OpenMPClause.h:802

Parameters

const clang::OMPClause* T

clang::SourceLocation getLParenLoc() const

Description

Returns the location of '('.

Declared at: clang/include/clang/AST/OpenMPClause.h:784

clang::Expr* getSafelen() const

Description

Return safe iteration space distance.

Declared at: clang/include/clang/AST/OpenMPClause.h:787

void setLParenLoc(clang::SourceLocation Loc)

Description

Sets the location of '('.

Declared at: clang/include/clang/AST/OpenMPClause.h:781

Parameters

clang::SourceLocation Loc

void setSafelen(clang::Expr* Len)

Description

Set safelen.

Declared at: clang/include/clang/AST/OpenMPClause.h:762

Parameters

clang::Expr* Len

clang::OMPClause::child_range used_children()

Declared at: clang/include/clang/AST/OpenMPClause.h:795

clang::OMPClause::const_child_range
used_children() const

Declared at: clang/include/clang/AST/OpenMPClause.h:798