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.

• Big data programs<br />

The maxdata field is used for 32-bit programs to indicate that the heap should<br />

be placed in a different place where a larger heap can be accommodated. In<br />

64-bit processes, the address space will always be able to accommodate a<br />

large heap, so no indication is necessary. The maxdata and maxstack fields, if<br />

set, are used to set the soft rlimit value for 32-bit and 64-bit applications. If the<br />

limit specified is greater than the hard rlimit values, the exec() will fail.<br />

3.2.2 System Calls<br />

Because the <strong>AIX</strong> kernel remains 32-bit, the interfaces to the various system calls<br />

must be through the types and structures of 32-bit mode C. 64-bit mode<br />

applications, however, are compiled with 64-bit mode types and structures. This<br />

section explains how the different types are communicated to the kernel.<br />

On a 64-bit PowerPC, <strong>AIX</strong> will run both 32-bit-mode processes and 64-bit-mode<br />

processes. The problem is that 64-bit applications compiled with the same <strong>AIX</strong><br />

header files that 32-bit processes use (but compiled for 64-bit execution mode)<br />

build data structures, arrays, and scalars using the rules of 64-bit C, though the<br />

kernel expects data structures, arrays, and scalars that match the ones built by<br />

32-bit applications using 32-bit C. If a 64-bit application builds, for example, an<br />

ioveC structure containing an address and a length, this structure cannot be<br />

passed directly to the kernel's kreadv() system call routine because that routine<br />

cannot interpret the 64-bit address and 64-bit length.<br />

Clearly, some code must be placed between the 64-bit application's system calls<br />

and the 32-bit kernel (see Figure 6). <strong>AIX</strong> takes advantage of the following two<br />

features in implementing this interface code:<br />

• The 32-bit and 64-bit name spaces are completely separate, and calls from<br />

64-bit applications are never resolved to 32-bit entry points. Specifically, the<br />

calls from 64-bit applications to traditional system call entry points should not<br />

be resolved to the 32-bit entry points of the same names exported by the<br />

kernel.<br />

• Since UNIX no longer makes a distinction between system calls and<br />

subroutines, it is no longer necessary to strictly follow the old UNIX semantics.<br />

If a caller passes a bad address to any system-supplied subroutine (whether<br />

system call or not), it is permissible to end the calling process, as will happen<br />

if a library routine dereferences an invalid pointer. This means that routines,<br />

traditionally considered to be system calls, can reside in subroutine libraries,<br />

and almost all of the system call interface code needed for 64-bit processes<br />

can be placed in a user-mode library such as libc.a.<br />

64-Bit Enablement 37

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

Saved successfully!

Ooh no, something went wrong!