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.

Using <strong>XL</strong> <strong>Fortran</strong> in a 64-Bit Environment<br />

The 64-bit environment addresses an increasing demand <strong>for</strong> larger storage<br />

requirements and greater processing power. The <strong>AIX</strong> operating system provides an<br />

environment that allows you to develop and execute programs that exploit 64-bit<br />

processors through the use of 64-bit pointers and 64-bit integers. <strong>XL</strong> <strong>Fortran</strong> only<br />

supports applications that target the 64-bit Large Data Type (LDT) Application<br />

Binary Interface (ABI). Non-LDT environments, such as <strong>AIX</strong> version 4, are no<br />

longer supported.<br />

To support larger executables that can be fit within a 64-bit address space, a<br />

separate, 64-bit object <strong>for</strong>m is used to meet the requirements of 64-bit executables.<br />

The binder binds 64-bit objects to create 64-bit executables. Note that objects that<br />

are bound together, statically or shared, must all be of the same object <strong>for</strong>mat. The<br />

following scenarios are not permitted and will fail to load, or execute, or both:<br />

v A 64-bit object or executable that has references to symbols from a 32-bit library<br />

or shared library<br />

v A 32-bit object or executable that has references to symbols from a 64-bit library<br />

or shared library<br />

v A 64-bit executable that attempts to explicitly load a 32-bit module<br />

v A 32-bit executable that attempts to explicitly load a 64-bit module<br />

v Attempts to run 64-bit applications on 32-bit plat<strong>for</strong>ms<br />

On both 64-bit and 32-bit plat<strong>for</strong>ms, 32-bit executables will continue to run as they<br />

currently do on a 32-bit plat<strong>for</strong>m.<br />

The <strong>XL</strong> <strong>Fortran</strong> compiler mainly provides 64-bit mode support through the<br />

compiler option -q64 in conjunction with the compiler option -qarch. This<br />

combination determines the bit mode and instruction set <strong>for</strong> the target architecture.<br />

The -q32 and -q64 options take precedence over the setting of the -qarch option.<br />

The -q64 option will win over a 32-bit mode only -qarch setting, and the compiler<br />

will upgrade the -qarch setting to something that will handle 64-bit mode.<br />

Conflicts between the -q32 and -q64 options are resolved by the ″last option wins″<br />

rule. Setting -qarch=com will ensure future compatibility <strong>for</strong> applications in 32–bit<br />

mode. For 64-bit mode applications, use -qarch=ppc64 to achieve the same effect<br />

<strong>for</strong> all present or future supported 64-bit mode systems. -qarch settings that target<br />

a specific architecture, like the 603, 604, rs64a, rs64b, rs64c, pwr3, pwr4, pwr5,<br />

ppc970, and auto settings will be more system-dependent.<br />

64-Bit Large Data Type Support<br />

The 64-bit Large Data Type (LDT) Application Binary Interface (ABI), or 64-bit LDT<br />

ABI, increases scalability <strong>for</strong> 64-bit applications, while maintaining binary<br />

compatibility <strong>for</strong> existing 32-bit applications. To accomplish this, some<br />

system-derived types are increased from 32-bits to 64-bits. In addition, a new 64-bit<br />

magic number is being introduced in the XCOFF definition to identify object code<br />

files using the new 64-bit ABI.<br />

The <strong>AIX</strong> 4.3 64-bit, non-LDT, ABI is no longer supported on <strong>AIX</strong> 5.1. Object code<br />

files with the old 64-bit magic number will not link, load, or execute. Pre-<strong>AIX</strong> 5.1<br />

64-bit applications must be recomplied in order to execute them on <strong>AIX</strong> 5.1. Binary<br />

compatibility will be preserved <strong>for</strong> 32-bit objects generated on all earlier levels of<br />

<strong>AIX</strong>, regardless of LDT support.<br />

© Copyright <strong>IBM</strong> Corp. 1990, 2004 279

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

Saved successfully!

Ooh no, something went wrong!