06.03.2014 Views

Intel Fortran Language Reference - NCI National Facility

Intel Fortran Language Reference - NCI National Facility

Intel Fortran Language Reference - NCI National Facility

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

14 <strong>Intel</strong> <strong>Fortran</strong> <strong>Language</strong> <strong>Reference</strong><br />

4. Add the results from steps 2 and 3.<br />

5. Store the results from step 4 into the location indicated by A(INDARR(I)) from step 1.<br />

IVDEP directs the compiler to initially assume that when steps 1 and 5 access a common memory<br />

location, step 1 always accesses the location first because step 1 occurs earlier in the execution<br />

sequence. This approach lets the compiler reorder instructions, as long as it chooses an instruction<br />

schedule that maintains the relative order of the array references.<br />

See Also<br />

“Rules for General Directives that Affect DO Loops”<br />

LOOP COUNT Directive<br />

The LOOP COUNT directive specifies the loop count for a DO loop; this assists the optimizer<br />

This directive takes the following form:<br />

cDEC$ LOOP COUNT (n)<br />

–or–<br />

cDEC$ LOOP COUNT = n<br />

c<br />

Is one of the following: C (or c), !, or * (see “Syntax Rules for Compiler Directives”).<br />

n<br />

Is an integer constant.<br />

Rules and Behavior<br />

The value of the loop count affects heuristics used in software pipelining, vectorization, and<br />

loop-transformations.<br />

Example<br />

Consider the following:<br />

cDEC$ LOOP COUNT (10000)<br />

do i =1,m<br />

b(i) = a(i) +1 ! This is likely to enable<br />

! the loop to get software-pipelined<br />

enddo<br />

See Also<br />

“Rules for General Directives that Affect DO Loops”<br />

14-26

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!