JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Oracle Solaris Studio 12.3: Fortran User's Guide     Oracle Solaris Studio 12.3 Information Library
search filter icon
search icon

Document Information

Preface

1.  Introduction

2.  Using Solaris Studio Fortran

3.  Fortran Compiler Options

4.  Solaris Studio Fortran Features and Extensions

5.  FORTRAN 77 Compatibility: Migrating to Solaris Studio Fortran

A.  Runtime Error Messages

B.  Features Release History

C.  Fortran Directives Summary

C.1 General Fortran Directives

C.2 Special Fortran Directives

C.3 Fortran OpenMP Directives

Index

C.1 General Fortran Directives

General directives accepted by f95 are described in 2.3 Directives.

Table C-1 Summary of General Fortran Directives

Format
!$PRAGMA keyword ( a [ , a ] … ) [ , keyword ( a [ , a ] … ) ] ,…

!$PRAGMA SUN keyword ( a [ , a ] … ) [ , keyword ( a [ , a ] … ) ] ,…

Comment-indicator in column 1 may be c, C, !, or *. (We use ! in these examples. f95 free-format must use !.)

C Directive
!$PRAGMA C(list)

Declares a list of names of external functions as C language routines.

IGNORE_TKR Directive
!$PRAGMA IGNORE_TKR {name {, name} ...}

The compiler ignores the type, kind, and rank of the specified dummy argument names appearing in a generic procedure interface when resolving a specific call.

UNROLL Directive
!$PRAGMA SUN UNROLL=n

Advises the compiler that the following loop can be unrolled to a length n.

WEAK Directive
!$PRAGMA WEAK(name[=name2])

Declares name to be a weak symbol, or an alias for name2.

OPT Directive
!$PRAGMA SUN OPT=n

Set optimization level for a subprogram to n.

PIPELOOP Directive
!$PRAGMA SUN PIPELOOP[=n]

Assert dependency in loop between iterations n apart.

PREFETCH Directives
!$PRAGMA SUN_PREFETCH_READ_ONCE (name)

!$PRAGMA SUN_PREFETCH_READ_MANY (name)

!$PRAGMA SUN_PREFETCH_WRITE_ONCE (name)

!$PRAGMA SUN_PREFETCH_WRITE_MANY (name)

Request compiler generate prefetch instructions for references to name. (Requires -xprefetch option, which is enabled by default. Prefetch directives can be disabled by compiling with —xprefetch=no. Target architecture must also support prefetch instructions, and the compiler optimization level must be set greater than —xO2.)

ASSUME Directives
!$PRAGMA [BEGIN} ASSUME (expression [,probability])

!$PRAGMA END ASSUME

Make assertions about conditions at certain points in the program that the compiler can assume are true.