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.

v<br />

v<br />

Do not use names that are the same as names in the <strong>XL</strong> <strong>Fortran</strong> library or one of<br />

the system libraries. To determine which names are not safe to use in your<br />

program, run the nm command on any libraries that are linked into the program<br />

and search the output <strong>for</strong> names you suspect might also be in your program.<br />

If your program calls certain <strong>XL</strong>F-provided routines, some restrictions apply to<br />

the common block and subprogram names that you can use:<br />

<strong>XL</strong>F-Provided Function Name<br />

mclock<br />

rand<br />

Common Block or Subprogram Name You<br />

Cannot Use<br />

times<br />

irand<br />

Be careful not to use the names of subroutines or functions without defining the<br />

actual routines in your program. If the name conflicts with a name from one of the<br />

libraries, the program could use the wrong version of the routine and not produce<br />

any compile-time or link-time errors.<br />

If different versions of a routine occur in more than one library or object file, be<br />

careful to use the specific version that you want. Specify the file with the correct<br />

version as the first file on the command line or in the configuration file. If the file<br />

is a library, specify the appropriate -l option first on the command line. This<br />

technique does not apply to references between routines that are in the same<br />

shared library or to routines that are explicitly imported from one shared library to<br />

another.<br />

Running <strong>XL</strong> <strong>Fortran</strong> Programs<br />

The default file name <strong>for</strong> the executable program is a.out. You can select a different<br />

name with the -o compiler option. You should avoid giving your programs the<br />

same names as system or shell commands (such as test or cp), as you could<br />

accidentally execute the wrong command. If a name conflict does occur, you can<br />

execute the program by specifying a path name, such as ./test.<br />

You can run a program by entering the path name and file name of an executable<br />

object file along with any run-time arguments on the command line.<br />

Canceling Execution<br />

To suspend a running program, press the Ctrl+Z key while the program is in the<br />

<strong>for</strong>eground. Use the fg command to resume running.<br />

To cancel a running program, press the Ctrl+C key while the program is in the<br />

<strong>for</strong>eground.<br />

Running Previously Compiled Programs<br />

Statically linked programs that you compiled with levels of <strong>XL</strong> <strong>Fortran</strong> prior to<br />

Version 9.1 should continue to run with no change in per<strong>for</strong>mance or behavior.<br />

They may not run on a system with a level of the operating system different from<br />

the system on which they were compiled.<br />

If you have dynamically linked programs compiled by <strong>XL</strong> <strong>Fortran</strong> Versions 2<br />

through 8, you can run them on systems with the <strong>XL</strong> <strong>Fortran</strong> Version 9 libraries.<br />

The programs will use the current compiler data <strong>for</strong>mats and I/O behavior, which<br />

are somewhat different from those of <strong>XL</strong> <strong>Fortran</strong> Version 2.<br />

48 <strong>XL</strong> <strong>Fortran</strong> <strong>Enterprise</strong> <strong>Edition</strong> <strong>for</strong> <strong>AIX</strong> : User’s <strong>Guide</strong>

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

Saved successfully!

Ooh no, something went wrong!