Compaq Fortran
User Manual for
Tru64 UNIX and Linux Alpha Systems


Previous Contents Index

Chapter 12
12 Compaq Fortran Library Routines
     12.1     Reference Pages for the 3f and 3hpf Routines
     12.2     EXTERNAL or INTRINSIC Declarations
     12.3     Types of Compaq Fortran 3f Library Routines
     12.4     Summary of 3f Library Routines
     12.5     Summary of 3hpf HPF_LOCAL_LIBRARY Library Routines
     12.6     Example of the 3f Library Routine shcom_connect
     12.7     Example of the 3f Library Routines irand and qsort
Chapter 13
13 Using the Compaq Extended Math Library (CXML)
     13.1     CXML Routine Groups
     13.2     Using CXML from Fortran
     13.3     CXML Program Example
Appendix A
Appendix A Compatibility: Compaq Fortran 77 and Compaq Fortran on Multiple Platforms
     A.1     Compaq Fortran and Compaq Fortran 77 Compatibility on Various Platforms
     A.2     Compatibility with Compaq Fortran 77 for Compaq Tru64 UNIX Systems
         A.2.1         Major Language Features for Compatibility with Compaq Fortran 77 for Compaq Tru64 UNIX Systems
         A.2.2         Language Features Provided Only by Compaq Fortran 77 for Compaq Tru64 UNIX Systems
         A.2.3         Improved Compaq Fortran Compiler Diagnostic Detection
         A.2.4         Compiler Command-Line Differences
     A.3     Language Compatibility with Compaq Visual Fortran
     A.4     Compatibility with Compaq Fortran 77 and Compaq Fortran for OpenVMS Systems
         A.4.1         Language Features Specific to Compaq Fortran 77 and Compaq Fortran for OpenVMS Systems
         A.4.2         OpenVMS Data Porting Considerations
             A.4.2.1             Matching Record Types
             A.4.2.2             Copying Files
         A.4.3         Nonnative VAX Floating-Point Representations
             A.4.3.1             VAX F_float REAL (KIND=4) or REAL*4
             A.4.3.2             VAX G_float REAL (KIND=8) or REAL*8
             A.4.3.3             VAX D_float REAL (KIND=8) or REAL*8
             A.4.3.4             VAX F_float COMPLEX (KIND=4) or COMPLEX*8
             A.4.3.5             VAX G_float and D_float COMPLEX (KIND=8) or COMPLEX*16
             A.4.3.6             VAX H_float Representation
Appendix B
Appendix B Compaq Fortran Environment Variables
     B.1     Commands for Setting and Unsetting Environment Variables
         B.1.1         Bourne Shell (sh) and Bourne Again Shell (bash) and Korn Shell (ksh) Commands
         B.1.2         C Shell (csh) Commands
     B.2     Compile-Time Environment Variable
     B.3     Run-Time Environment Variables
Appendix C
Appendix C Compiler Output Listings
     C.1     Source-Code Section
     C.2     Machine-Code Section
     C.3     Compilation Summary Section
Appendix D
Appendix D Parallel Library Routines
     D.1     OpenMP Fortran API Run-Time Library Routines
         D.1.1         omp_set_num_threads
         D.1.2         omp_get_num_threads
         D.1.3         omp_get_max_threads
         D.1.4         omp_get_thread_num
         D.1.5         omp_get_num_procs
         D.1.6         omp_in_parallel
         D.1.7         omp_set_dynamic
         D.1.8         omp_get_dynamic
         D.1.9         omp_set_nested
         D.1.10         omp_get_nested
         D.1.11         Lock Routines
             D.1.11.1             omp_init_lock
             D.1.11.2             omp_destroy_lock
             D.1.11.3             omp_set_lock
             D.1.11.4             omp_unset_lock
             D.1.11.5             omp_test_lock
     D.2     Other Parallel Threads Routines
         D.2.1         Calling Conventions
         D.2.2         _OtsInitParallel
         D.2.3         _OtsStopWorkers or mpc_destroy
         D.2.4         _OtsGetNumThreads or mpc_numthreads
         D.2.5         _OtsGetMaxThreads or mpc_maxnumthreads
         D.2.6         _OtsGetThreadNum or mpc_my_threadnum
         D.2.7         _OtsInParallel or mpc_in_parallel_region
Index
Index
Examples
1-1 Sample Main Program
1-2 Sample Main Program that Uses a Module and Separate Function
1-3 Sample Module
1-4 Sample Separate Function Declaration
4-1 Sample Program SQUARES
4-2 Sample Debugging Session Using Program Squares
5-1 Using the -assume dummy_aliases Option
6-1 Aligned Loop
6-2 Transformed Loop Using Code Replication
6-3 Distributed Loop
6-4 Decomposed Loop Using Locks
6-5 Decomposed Loop Using a Reduction Clause
6-6 Code Using Parallel Region
6-7 Code Using Multiple Threads
6-8 Code Using Multiple Processors
6-9 Code Using Shared Variables
6-10 Code Looking at a Shared Variable Value
7-1 C Function Called by USEROPEN Procedure
7-2 Compaq Fortran USEROPEN Main Calling Program
8-1 Error Handling OPEN Statement File Name
11-1 Calling C Functions and Passing Integer Arguments
11-2 Calling C Functions and Passing Integer Arguments
11-3 Compaq Fortran Program Calling a Compaq Fortran 77 Subroutine
11-4 Compaq Fortran 77 Subroutine Called by a Compaq Fortran Program
11-5 C Functions Called by a Compaq Fortran Program
11-6 Calling C Functions and Passing Integer Arguments
11-7 Compaq Fortran Program Calling a C Function
11-8 C Interface Function Called by Compaq Fortran
11-9 Calling C Functions and Passing Complex Arguments
11-10 Calling C Functions and Passing Pointer Arguments
11-11 C Functions Receiving Pointer Arguments
11-12 C Function That Receives an Explicit-Shape Array
11-13 Compaq Fortran Program That Passes an Explicit-Shape Array
12-1 Using the 3f Routine shcom_connect
12-2 Using the 3f Routines irand and qsort
C-1 Sample Source Code Listing
C-2 Sample Machine-Code Listing
C-3 Sample Compilation Summary
Figures
2-1 f90 Driver Program and Software Components
5-1 Common Block with Unaligned Data
5-2 Common Block with Naturally Aligned Data
5-3 Common Block with Naturally Aligned Reordered Data
5-4 Derived-Type Naturally Aligned Data (in CATALOG_SPRING : ( ,))
5-5 Memory Diagram of REC for Naturally Aligned Records
7-1 Fixed-Length Records
7-2 Variable-Length Records
7-3 Segmented Records
7-4 Stream File
7-5 Stream_CR and Stream_LF Records
9-1 INTEGER (KIND =1) or INTEGER*1 Representation
9-2 INTEGER (KIND =2) or INTEGER*2 Representation
9-3 INTEGER (KIND =4) or INTEGER*4 Representation
9-4 INTEGER (KIND =8) or INTEGER*8 Representation
9-5 LOGICAL Representations
9-6 REAL (KIND =4) or REAL*4 Representation
9-7 REAL (KIND =8) or REAL*8 Representation
9-8 REAL (KIND =16) or REAL*16 Representation
9-9 COMPLEX (KIND =4) or COMPLEX*8 Representation
9-10 COMPLEX (KIND =8) or COMPLEX*16 Representation
9-11 COMPLEX (KIND =16) or COMPLEX*32 Representation
9-12 CHARACTER Data Representation
10-1 Little and Big Endian Storage of an INTEGER Value
10-2 Sample Unformatted File Conversion
A-1 VAX F_float REAL (KIND =4) or REAL*4 Representation
A-2 VAX G_float REAL (KIND =8) or REAL*8 Representation
A-3 VAX D_float REAL (KIND =8) or REAL*8 Representation
A-4 VAX F_float COMPLEX (KIND =4) or COMPLEX*8 Representation
A-5 VAX G_float COMPLEX (KIND =8) or COMPLEX*16 Representation
A-6 VAX D_float COMPLEX (KIND =8) or COMPLEX*16 Representation
A-7 VAX H_float REAL*16 Representation (VAX Systems)
Tables
1 Platform Labels
2 Conventions Used in This Document
1-1 Main Tools for Program Development and Testing
2-1 File Suffixes Recognized as Fortran 95/90 Source Files
2-2 Other File Name Suffixes
2-3 Compiler Limits
2-4 Libraries Automatically Searched When Using the f90 Command
3-1 f90 and fort Command Options and Categories
3-2 Interaction of File Suffix and the -free and -fixed Options on Source Form
3-3 Summary of Floating-Point Exception Command Options
4-1 Summary of Symbol Table Command Options
4-2 Summary of Debugger Commands
5-1 Options Related to Run-Time Performance
5-2 Options that Slow Run-Time Performance
5-3 Output Argument Array Types
5-4 Levels of Optimization with Different -O n Options
6-1 OpenMP Fortran API Compiler Directives
6-2 Initialization Values
6-3 Compaq Fortran Parallel Compiler Directives
6-4 OpenMP Fortran API Environment Variables
6-5 Compaq Fortran Environment Variables
7-1 Summary of I/O Statements
7-2 Available I/O Statements and Record I/O Forms
7-3 Compaq Fortran Record Types
7-4 Preconnected Files and Environment Variables
7-5 OPEN Statement Functions and Specifiers
7-6 Examples of Applying Default Pathnames and File Names
7-7 Implicit Compaq Fortran Logical Units
7-8 Allowed Record Access for File Organizations and Record Types
8-1 Severity Levels of Run-Time Messages
8-2 Run-Time Error Messages and Explanations
9-1 Compaq Fortran Intrinsic Data Types, Storage, and Numeric Ranges
9-2 Exceptional Floating-Point Numbers
10-1 Unformatted Numeric Formats, Keywords, and Supported Data Types
11-1 Calling Conventions for ATTRIBUTES Options
11-2 C Property and External Names
11-3 C Property and Argument Passing
11-4 Compaq Fortran and C Data Types
12-1 Language Interface 3f Library Routines
12-2 3f Library Routines Providing Special Functions
12-3 Compaq Fortran 3f Functions and Subroutines
12-4 Compaq Fortran 3hpf HPF_LOCAL_LIBRARY Library Routines
13-1 CXML Routine Groups
A-1 Summary of Language Compatibility
A-2 Equivalent Record Types for OpenVMS Fortran and Compaq Fortran on Compaq Tru64 UNIX or Linux Alpha Systems
B-1 Compile-Time Environment Variable
B-2 Run-Time Environment Variables


Previous Next Contents Index