24.05.2014 Views

AIX Version 4.3 Differences Guide

AIX Version 4.3 Differences Guide

AIX Version 4.3 Differences Guide

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.

1506-003 (S) Width of a bit-field of type "long" cannot exceed 64.<br />

Bitfields are packed into the current word. Adjacent bitfields that cross a word<br />

boundary will start at a new storage unit. This storage unit is a word in power, full<br />

or natural alignment in 32-bit mode, but is a double word in 64-bit mode. In 64-bit<br />

mode, adjacent declarations of bitfields of type long can now be contained into<br />

one storage unit. Since long bitfields of greater than 32-bits were not permitted in<br />

32-bit mode, this does not change and is not a portability problem.<br />

Note that the packed alignment option just reduces the alignment ceiling to one,<br />

two, four, or eight bytes depending on the packed=1|2|4|8 setting and leaves the<br />

remaining alignment parameters unchanged.<br />

3.3.1.4 Enum Support<br />

Enum constants are always of type int, except when the range of these constants<br />

is beyond the range of int, in which case, they have type unsigned int. Enum<br />

variables may be smaller depending on the mode of -qenum=small|int|1|2|4|8<br />

option.<br />

small Specifies that enumeration occupies a minimum amount of storage<br />

(either 1, 2, 4, or 8 bytes) depending on the range of enum constants.<br />

int Enumeration occupies 4 bytes and are represented by int.<br />

1 Enumeration occupies 1 byte and are represented by char.<br />

2 Enumeration occupies 2 bytes and are represented by short.<br />

4 Enumeration occupies 4 bytes and are represented by int.<br />

8 Enumeration occupies 8 bytes and are represented by long.<br />

enum=int and enum=4 are not the same. The enum=4 allows signed and<br />

unsigned variant. The enum constants will usually be typed int, even in 64-bit<br />

mode, to enhance compatibility with 32-bit programs. Only when the range<br />

chooses an unsigned long or long, the constant will use unsigned long or long<br />

types respectively. In 32-bit mode, -qenum=8 will yield an warning message:<br />

1506-749 (W) Enum=8 is not valid in 32-bit mode, setting enum=4 instead.<br />

3.3.2 XL Fortran <strong>Version</strong> 5<br />

XL Fortran <strong>Version</strong> 5.1 introduced a new compiler option, -q64. This allows the<br />

object code to run in 64-bit mode. The programming conventions are similar to C.<br />

For a better understanding of Fortran tuning on POWER3 processors, see<br />

RS/6000 Scientific and Technical Computing: POWER3 Introduction and Tuning<br />

<strong>Guide</strong>, SG24-5155.<br />

3.3.3 System Libraries<br />

<strong>AIX</strong> <strong>4.3</strong> provides a 32-bit Application Binary Interface (ABI) and a 64-bit ABI. The<br />

32-bit ABI consists of the entire pre-<strong>AIX</strong> <strong>4.3</strong> ABI and provides binary compatibility<br />

at the same level as maintained by previous releases.<br />

The dual ABI means two different version of all the Application Program<br />

Interfaces (APIs). The mechanism for this are two separate versions of all the<br />

objects in a given library. The objects are distinguished by distinct names. The<br />

linker is able to distinguish which object to use for a given symbol based on the<br />

differing object formats (32-bit and 64-bit).<br />

64-Bit Enablement 61

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

Saved successfully!

Ooh no, something went wrong!