24.05.2014 Views

XL Fortran Enterprise Edition for AIX : User's Guide - IBM

XL Fortran Enterprise Edition for AIX : User's Guide - IBM

XL Fortran Enterprise Edition for AIX : User's Guide - IBM

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.

-qcache Option<br />

Syntax<br />

-qcache=<br />

{<br />

assoc=number |<br />

auto |<br />

cost=cycles |<br />

level=level |<br />

line=bytes |<br />

size=Kbytes |<br />

type={C|c|D|d|I|i}<br />

}[:...]<br />

Specifies the cache configuration <strong>for</strong> a specific execution machine. The compiler<br />

uses this in<strong>for</strong>mation to tune program per<strong>for</strong>mance, especially <strong>for</strong> loop operations<br />

that can be structured (or blocked) to process only the amount of data that can fit<br />

into the data cache.<br />

If you know exactly what type of system a program is intended to be executed on<br />

and that system has its instruction or data cache configured differently from the<br />

default case (as governed by the -qtune setting), you can specify the exact<br />

characteristics of the cache to allow the compiler to compute more precisely the<br />

benefits of particular cache-related optimizations.<br />

For the -qcache option to have any effect, you must include the level and type<br />

suboptions and specify at least level 2 of -O.<br />

v<br />

v<br />

v<br />

If you know some but not all of the values, specify the ones you do know.<br />

If a system has more than one level of cache, use a separate -qcache option to<br />

describe each level. If you have limited time to spend experimenting with this<br />

option, it is more important to specify the characteristics of the data cache than<br />

of the instruction cache.<br />

If you are not sure of the exact cache sizes of the target systems, use relatively<br />

small estimated values. It is better to have some cache memory that is not used<br />

than to have cache misses or page faults from specifying a cache that is larger<br />

than the target system has.<br />

Arguments<br />

assoc=number<br />

Specifies the set associativity of the cache:<br />

0 Direct-mapped cache<br />

1 Fully associative cache<br />

n > 1 n-way set-associative cache<br />

auto Automatically detects the specific cache configuration of the compiling<br />

machine. It assumes that the execution environment will be the same as<br />

the compilation environment.<br />

cost=cycles<br />

Specifies the per<strong>for</strong>mance penalty that results from a cache miss so that the<br />

compiler can decide whether to per<strong>for</strong>m an optimization that might result<br />

in extra cache misses.<br />

level=level<br />

Specifies which level of cache is affected:<br />

1 Basic cache<br />

<strong>XL</strong> <strong>Fortran</strong> Compiler-Option Reference 137

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

Saved successfully!

Ooh no, something went wrong!