Intel® Fortran Compiler Classic and Intel® Fortran Compiler Developer Guide and Reference

ID 767251
Date 3/22/2024
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

ALIGNED Clause

Parallel Directive Clause: Specifies that all variables in a list are aligned.

Syntax

ALIGNED (list [:n])

list

Is the name of one or more variables. Each name must be separated by a comma. Any variable that appears in list cannot appear in more than one ALIGNED clause.

n

Must be a constant positive integer expression; it indicates the number of bytes for the alignment. If n is not specified, the compiler uses the default alignment specified for SIMD instructions on the target platform.

The ALIGNED clause declares that the location of each list item is aligned to the number of bytes expressed in the optional alignment parameter n of the ALIGNED clause. If a list item has the ALLOCATABLE attribute, its allocation status must be allocated. If it has the POINTER attribute, its association status must be associated. If the type of a list item is type(C_PTR) or a Cray pointer, the item must be defined.

NOTE:

Be careful when using the ALIGNED clause. Instructing the compiler to implement all array references with aligned data movement instructions will cause a runtime exception if some of the access patterns are actually unaligned.