Planning for IBM PASE for i
PASE for i provides an AIX® runtime environment on the IBM® i operating system so that you can port your AIX applications to the system with minimal effort.
In fact, many AIX programs run in PASE for i with no change. This is because PASE for i supplies many of the same shared libraries that are available on AIX, and it provides a broad subset of AIX utilities that run directly on the IBM i PowerPC® processor in the same way that they run on the System p PowerPC processor.
Keep in mind these points as you begin to work with PASE for i:
- There is a correlation between the target AIX binary release and the release of PASE for i where the binary
application will run.
If you compile your PASE for i applications on AIX, the binary version of the application created on AIX needs to be compatible with the version of PASE for i in which you want to run the application. The following table shows which AIX binary versions are compatible with different versions of PASE for i. For example, an application created for AIX release 5.3 can only run in PASE for i on IBM i 5.4 and subsequent releases. Similarly, an application created for AIX release 6.1 can run on IBM i 7.1, but not on any of the previous releases.
AIX release IBM i 7.2 IBM i 7.3 IBM i 7.4 5.3 (32- or 64-bit) X X X 6.1 (32- or 64-bit) X X X 7.1 (32- or 64-bit) X X X 7.2 (32- or 64-bit) X
- PASE for i does
not provide the AIX kernel on
the IBM i operating
Instead, any low-level system functions that are needed by a shared library are routed to the IBM i kernel or to the integrated IBM i functions. In this regard, PASE for i bridges the gap across the AIX and IBM i operating systems. Your code uses the same syntax for the APIs in the shared libraries as you can find on AIX, but your PASE for i program runs within an IBM i job and is managed by the IBM i operating system just like any other IBM i job.
- In most cases, the APIs you call in PASE for i behave in exactly
the same manner as they do on AIX.
Some APIs, however, might behave differently in PASE for i, or might not be supported in PASE for i. Because of this, your plan for preparing PASE for i programs should begin with a thorough code analysis. For more information about code analysis, see Analyzing program compatibility with IBM PASE for i.
- Consider some of the differences that exist between the AIX and IBM i platforms:
- AIX is generally case-sensitive, but certain IBM i file systems are not.
- AIX generally uses ASCII
for data encoding, but the IBM i operating
system generally uses Extended Binary Coded Decimal Interchange Code
(EBCDIC). This is a consideration if you want to manage the details
of calling ILE code from your PASE for i program. For
example, you must explicitly code PASE for i programs to handle
character encoding conversions on strings when you make calls from PASE for i to arbitrary
ILE procedures. PASE for i runtime
support includes the iconv(), iconv_close(), and iconv_open() functions
for character encoding conversion. Note: PASE for i and ILE have independent implementations of iconv() interfaces, each with its own translation tables. The translations supported by PASE for i iconv() support can be modified and extended by users because they are stored as byte stream files in the integrated file system.
- AIX applications expect that lines (for example, in files and shell scripts) will end with a line feed (LF), but personal computer (PC) software and IBM i software typically end lines with a carriage return and line feed (CRLF).
- Some of the scripts and programs you use on AIX might use hardcoded paths to standard utilities, and you might need to modify the path to reflect the paths you are using in PASE for i. You should analyze your program's compatibility with the IBM i operating system.
PASE for i automatically handles some of these issues. For example, when you use the PASE for i runtime service that the system provides (including any system call or runtime function in a shared library shipped with IBM i option 33), PASE for i performs ASCII-to-EBCDIC conversions as needed, although generally no conversions are done for data that is read or written to a file descriptor (byte stream file or socket).
You can use other low-level functions, such as _ILECALL(), to extend the functionality of your PASE for i program with calls to ILE functions and APIs, but as mentioned above you might need to handle data conversion. Also, coding these extensions into your program requires the use of additional header and export files.