
VSI OpenVMS Pascal for OpenVMS User Manual Publication Date: XXXXXX This manual contains information about selected programming tasks using the VSI Pascal programming language. Operating system and Version: VSI OpenVMS version X.X Software Version: VSI OpenVMS version X.X VMS Software, Inc., (VSI) Bolton, Massachusetts, USA VSI OpenVMS Pascal for OpenVMS User Manual: Copyright © 2018 VMS Software, Inc., (VSI), Bolton Massachusetts, USA Legal Notice Confidential computer software. Valid license from VSI required for possession, use or copying. Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license. The information contained herein is subject to change without notice. The only warranties for VSI products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. VSI shall not be liable for technical or editorial errors or omissions contained herein. HPE, HPE Integrity, HPE Alpha, and HPE Proliant are trademarks or registered trademarks of Hewlett Packard Enterprise. Intel, Itanium and IA64 are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States and other countries. Java, the coffee cup logo, and all Java based marks are trademarks or registered trademarks of Oracle Corporation in the United States or other countries. Kerberos is a trademark of the Massachusetts Institute of Technology. Microsoft, Windows, Windows-NT and Microsoft XP are U.S. registered trademarks of Microsoft Corporation. Microsoft Vista is either a registered trademark or trademark of Microsoft Corporation in the United States and/or other countries. Motif is a registered trademark of The Open Group UNIX is a registered trademark of The Open Group. The VSI OpenVMS documentation set is available on DVD. ii Pascal for OpenVMS User Manual Chapter 1. Compiling VSI Pascal Programs ...................................................................... 1 1.1. PASCAL Command ........................................................................................................ 1 1.1.1. PASCAL Command Examples ................................................................................ 2 1.1.2. PASCAL Qualifiers .............................................................................................. 2 1.1.3. Contents of the Compilation Listing File ................................................................. 18 1.1.4. Text Libraries ..................................................................................................... 20 1.2. LINK Command ........................................................................................................... 22 1.2.1. LINK Command Examples ................................................................................... 22 1.2.2. LINK Qualifiers ................................................................................................. 23 1.2.3. Object Module Libraries ...................................................................................... 23 1.3. RUN Command ............................................................................................................ 24 1.4. Error Messages ............................................................................................................. 24 Chapter 2. Separate Compilation ...................................................................................... 25 2.1. ENVIRONMENT, HIDDEN, and INHERIT Attributes ......................................................... 25 2.2. Interfaces and Implementations ........................................................................................ 29 2.3. Data Models ................................................................................................................. 32 2.4. Separate Compilation Examples ....................................................................................... 35 Chapter 3. Program Correctness, Optimization, and Efficiency .................................... 39 3.1. Compiler Optimizations .................................................................................................. 39 3.1.1. Compile-Time Evaluation of Constants ................................................................... 40 3.1.2. Elimination of Common Subexpressions ................................................................. 41 3.1.3. Elimination of Unreachable Code .......................................................................... 42 3.1.4. Code Hoisting from Structured Statements .............................................................. 42 3.1.5. Inline Code Expansion for Predeclared Functions ..................................................... 42 3.1.6. Inline Code Expansion for User-Declared Routines ................................................... 43 3.1.7. Testing for Inline Expansion on VSI OpenVMS VAX Systems .................................... 43 3.1.8. Operation Rearrangement ..................................................................................... 44 3.1.9. Partial Evaluation of Logical Expressions ................................................................ 44 3.1.10. Value Propagation ............................................................................................. 44 3.1.11. Strength Reduction ( VSI OpenVMS I64 and VSI OpenVMS Alpha systems) ............... 45 3.1.12. Split Lifetime Analysis ( VSI OpenVMS I64 and VSI OpenVMS Alpha systems) .......... 45 3.1.13. Code Scheduling ( VSI OpenVMS I64 and VSI OpenVMS Alpha systems) .................. 45 3.1.14. Loop Unrolling ( VSI OpenVMS I64 and VSI OpenVMS Alpha systems) .................... 46 3.1.15. Alignment of Compiler-Generated Labels .............................................................. 46 3.1.16. Error Reduction Through Optimization ................................................................. 46 3.1.17. Software Pipelining ( VSI OpenVMS I64 and VSI OpenVMS Alpha systems) ............... 47 3.1.18. Processor Selection and Tuning ( VSI OpenVMS Alpha systems) ............................... 47 3.1.19. Compiling for Optimal Performance ..................................................................... 48 3.2. Programming Considerations ........................................................................................... 48 3.3. Implementation-Dependent Behavior ................................................................................ 49 3.3.1. Subexpression Evaluation Order ............................................................................ 49 3.3.2. MAXINT and MAXINT64 Predeclared Constants .................................................... 50 3.3.3. Pointer References .............................................................................................. 50 3.3.4. Variant Records .................................................................................................. 51 3.3.5. Atomicity, Granularity, Volatility, and Write Ordering ................................................ 51 3.3.6. Debugging Considerations .................................................................................... 52 Chapter 4. Programming Tools ......................................................................................... 55 4.1. Debugger Support for VSI Pascal .................................................................................... 55 4.2. Language-Sensitive Editor/Source Code Analyzer Support for VSI Pascal ................................ 56 4.2.1. Programming Language Placeholders and Tokens ..................................................... 56 4.2.2. Placeholder and Design Comment Processing .......................................................... 56 4.2.3. LSE and SCA Examples ...................................................................................... 57 4.3. Accessing CDD/Repository from VSI Pascal ...................................................................... 60 4.3.1. Equivalent VSI Pascal and CDDL Data Types .......................................................... 61 4.3.2. CDD/Repository Example .................................................................................... 62 iii Pascal for OpenVMS User Manual Chapter 5. Calling Conventions ........................................................................................ 65 5.1. VSI OpenVMS Calling Standard ...................................................................................... 65 5.1.1. Parameter Lists .................................................................................................. 65 5.1.2. Function Return Values ........................................................................................ 65 5.1.3. Contents of the Call Stack .................................................................................... 66 5.1.4. Unbound Routines .............................................................................................. 68 5.2. Parameter-Passing Semantics ........................................................................................... 68 5.3. Parameter-Passing Mechanisms ........................................................................................ 68 5.3.1. By Immediate Value ............................................................................................ 69
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages212 Page
-
File Size-