GC33-0001-2 File No. S360/S370-29

OS PL/I Optimizing : Program Product General Information

Program Number 5734-PL 1 (This program product is available as part of composite package 5734-PL3) Reiised June~ 1973 By TNL: GN33-6095

Preface

This publication gives general information substitution of in-line code in place of about the Q§ !:!!L! QE:£!!!!iz!!!g £2!!lE!!~!:" a calls to . processing program of the IBM Operating :System. Chapter 3 is about the PL/I language itself, including the features that can be The information provided is to be used used with this compiler, and a comparison as a planning aid only, and is intended to of the language imple~ented by the introduce installation managers, systems with that implemented .analysts, and to the facilities by version 5 of the PL/I (F) compiler. available with this compiler. The reader is assumed to be conversant with the IBM Chapter 4 briefly describes both the and with the PL/I language machine and the operating system as implemented by version 5 of the PL/I (F) requirements of the optimizing compiler. compiler. Appendix A is a list of the PL/I and the Chapter 1 discusses how the performance implementation-defined keywords used by of the OS PL/I Optimizing Compiler compares this compiler. with that of version 5 of the PL/I (F) Compiler; the compiler options that are Appendix B documents the most available; the aids designed to significant incompatibilities that might increase productivity; the cause a program written for version 5 of degree to which the compiler is compatible the PL/I (F) Compiler to give errors when with version 5 of the PL/I (F) Compiler; run on the optimizing compiler. and the features designed to allow I communication with assembler programs and Appendix is a bibliography of related Iwith programs written in COBOL or . IBM publications and their order numbers.

Chapter 2 is a discussion of the methods Appendix 0 provides planning information used for the optimization process;, such as for the use of the optimizing compiler expression simplification or the under CMS.

Third Edition (December 1972)

This is a major revision of, and obsoletes, GC33-0001-1 and Technical Newsletters GN33-6069, GN33-6057, GN33-6044. GN33-6034, and GN33-6024. Changes or additions to the text and figures are indicated by a vertical line to the left of the change.

This edition applies to Version 1, Release 2, Modification 0 of the OS PL/I Optimizing Compiler, Program Product 5734-PL1, and to all subsequent versions, releases, or modifications until otherwise indicated in new editions or technical newsletters. Changes are continually made to the information herein; before using this pUblication in connection with the operation ot IBM Systems, consult the latest IBM System/360 and System/370 Bibliography, Order No. GA22-6822, and associated technical newsletters, for the editions that are applicable and current. VSAM material in this publication is for planning purposes only. CMS material in this publication applies to Release 1, PLC5(Program Level Change 5) of the Facility/370 (VM/370).

Requests for copies of IBM publications should be made to your IBM representative or the IBM branch office serving your locality.

A form for readers' comments is provided at the back of this publication. If the form has been removed, comments may be addressed to IBM united Kingdom Laboratories Ltd. Publications Department, Hursley Park, Winchester' Hampshire, England. Comments become the property'of IBM.

ecopyright International Business Machines Corporation 1970,1971,1972

ii Contents

INTRODUCTION 1 Data Aggregates • • • • 18 String Handling • • • • • 18 CHAPTER 1: THE OS PL/I OPTIMIZING Data Attributes 18 COMPILER • 3 Extended Precision Floating Compilation Speed • • 3 Point • • • • • • • • • • • 19 Speed • • • • • • • • • • • 3 Subroutines and Functions 19 Space Requirements . . . . 3 Mathematical Built-In Functions 20 Debugging Aids 3 comparison Operators • • • • 20 Compiler Options 4 Interlanguage Communication 20 Compatibility with the (F) Compiler • 5 compatibility Between Releases • • • 5 compatibility Between OS and DOS 5 CHAPTER 4: SYSTEM REQUIREMENTS • 21 Interlanguage Communication 5 Machine Requirements 21 Compilation . . . . 21 CHAPTER 2: OPTIMIZATION 7 Execution •••• . . . . 21 Common Expression Elimination 7 Auxiliary Storage 21 Transfer of Expressions from Loops 8 Input/Output Devices • 21 Redundant Expression Elimination 8 Operating System Requirements 22 Simplification of Expressions • • 8 Control Programs • • • • • • • 22 Modification of Loop Control Data Management Facilities • • 23 Variables • • • • • • • 9 Sort Facilities •••••• 23 Defactorization • • • • 9 Checkpoint/Restart Facilities 23 Replacement of constant System/370 Facilities 23 Expressions • • • • • • 9 Replacement of Constant APPENDIX A: KEYWORDS AND THEIR Multipliers and Exponents • 9 ABBREVIATIONS 25 Initialization of Arrays and Structures • • • • • • • • • 9 APPENDIX B: COMPATIBILITY WITH (F) In-line Code for Conversions 10 COMPILER • 31 In-line Code for RECORD I/O • • • 10 Areas ••••••••• 31 Rey Handling for REGIONAL Data Sets • 10 Arrays and structures • • • • • 31 Matching Format Lists With Data Lists 10 Built-In Functions • • 31 In-line Code for String Manipulation 10 The DISPLAY Statement 31 In-line Code for Built-In Functions • 10 Dumps from PL/I Programs • • 31 Special-case Code for DO Statements • 10 Entry Names, Parameters, and structure and Array Assignments • 11 Returned Values • • • • • • • • 31 Library Subroutines • • • • • • • • • 11 The ENVIRONMENT Attribute 32 Elimination of Common Constants • • • 11 Error Correction • 32 Elimination of Common Control Data 11 INITIAL Attribute 32 Use of Registers 11 LIKE Attribute • 32 Code for Program Branches • • • • • • 11 Link-Editing • • • 32 Operating System Facilities 32 CHAPTER 3: THE PL/I LANGUAGE Pictures • • • • 33 IMPLEMENTED • • • • 13 Preprocessor • • 33 Language Feature s • • • • • • 13 Pseudovariables 33 Data Types • • • 13 Record I/O ••• 33 Operations • • • • • • • 13 Redundant Expression Elimination 33 Data Aggregates 13 REWIND Option 33 Program Management • 13 SORT/MERGE Program • 33 Input/Output •• 14 Statements • • • • • • • • • 33 Language Extensions • • • 15 Statement Labels • • • • • • 33 optimization • • • • 15 statement Lengths 33 Program Checkout • 15 Stream Transmission 34 DEFAULT Statement 15 Varying-length strings • • • • • 34 preprocessing Facilities • 15 Listing Control Statements 16 APPENDIX C: BIBLIOGRAPHY. 35 storage Control •••••• 16 ENVIRONMENT Attribute 16 APPENDIX D: PLANNING INFORMATION FOR Record-Oriented Transmission • • 17 CMS • • • • • 37 ASCII Data Sets 17 File Names • • • • • • • • • 18 INDEX • 39

iii Figures

Figure 1. Differences in implementation restrictions 14 Figure 2. Compiler input/outputdevices •••••• 22

iv --~------Revised June, 1973 By TNL: GN33-6095

Introduction

The OS PL/I Optimizing Compiler is designed The OS PL/I Optimizing Compiler for the compilation of programs written in translates PL/I source statements into PL/I into efficient object programs. It machine instructions. However, it does not requires a minimum of 50K bytes of main generate all the machine instructions storage on an IBM System/360 or System/370 required to represent the source program; with the universal instruction set and is in some cases it inserts references to intended to meet the requirements of the subroutines that are stored in the resident PL/I user of medium-sized or larger library. During link-editing, subroutines installations. Good all-round performance from the resident library are included in is aChieved by a compiler design that the object module. These subroutines may incorporates the best design features of a contain references to other subroutines number of well-proven , including stored in the transient library; during the PL/I (D)~ PL/I (F), FORTRAN IV(G), execution, subroutines from the transient FORTRAN IV(H), and COBOL (F) compilers. library are loaded, executed, and discarded The main features include: as required.

• Extensive Optimization - if optional The functions provided by the resident optimization is specified, the machine library are as follows: instructions generated will be optimized using the features described in chapter • mathematical subroutines. 2, to produce a very efficient object program. some optimization is always • data type conversions. performed even if the option is not specified. A secondary effect of • edit-, list-, and data-directed I/O optimization could be a reduction in the (stream-oriented transmission). amount of main storage required for the object program during execution. If • program initialization. optional optimization is not specified" compilation time will be reduced. • storage management.

• Advanced Level of PL/I - an • display. implementation of PL/I with language extensions beyond the language • timer facilities. implemented by the PL/I (F) Compiler. New features for os users include: • error handling. DEFAULT statement The functions provided by the transient library are as follows: Entry variables • print and message subroutines of the File variables error and interrupt handling subroutines. • Extensive Debugging Aids - time and effort required for program checkout are • opening and closing files. minimized by: • record-oriented and stream-oriented Extensive implementation of on-units transmission. support of the CHECK condition These libraries are not an integral part of the OS PL/I Optimizing Compiler; they Data-directed input/output consist of the following separate IBM program products: Comprehensive range of compiler options • OS PL/I Resident Library, Program Number Clear and precise compile-time and 5734-LM4 execution-time diagnostic messages • as PL/I Transient Library, Program Optional statement number trace Number 5734-LM5 facilities Throughout this publication the terms optional statement frequency counting "resident library" and "transient library" facility. refer to these IBM program products.

Introduction 1

Page of GC33-0001-2 Revised June, 1973 By TNL: GN33-6095

Chapter 1: The OS PL/I Optimizing Compiler

The os PL/I Optimizing Compiler allows the The total CPU time of a sample of programmer the choice of fast compilation commercially-oriented programs that had of his source program or fast execution of been optimized was 30% less than that of the resulting object program. It does so the same sample compiled by version 5 of by means of a compiler option specifying the PL/I (F) Compiler with a range of the type of optimization required. saving on individual jobs between 0% and 59%. The compiler provides debugging aids to minimize the time and effort required for program checkout. Options are provided for use by the programmer to specify Within the samples, the least information or to request optional compiler improvement was typically shown by the facilities. The compiler is compatible shortest programs. The amount of with version 5 of the PL/I(F) compiler in improvement for any particular program terms of source language, except for a few depends on factors such as the overheads minor differences~ and there are features for initialization and input/output and the that allow programs compiled by the nature of the internal processing of the optimizing compiler to communicate with program. Programs most likely to show programs written in other languages. appreciable imfrovements in execution speed are those that contain features mentioned in chapter 2. Compila tion Speed Space Requirements compilation speed varies with the machine configuration, the version of the operating system, data set disposition, partition or The main storage requirements of the object region size. the complexity of the program. prog~ams produced by the optimizing and the language features and compiler compiler depend on the PL/I facilities options employed. In general, faster used. Space is required not only for the compilation will be achieved with larger generated by the compiler, but partitions or regions and minimum also for the resident library subroutines luse of compiler options. Use of the IBM that will be link-edited with it to form a 13330 Disk storage for compiler residence load module and for the transient library land the compiler spill file can decrease subroutines that are called when this load Icompilation time. module is executed. If optimization is I specified, the object code will usually I For programs that use the option require less space. lonly to include text from a source Istatement library, the INCLUDE option may Ibe used instead. giving a decrease in Icompilation time. Debugging Aids When optimization is requested, compilation times will increase by an The optimizing compiler provides the average of 25%; in some cases. the increase following debugging aids to minimize the may be as much as 100%. time and effort needed for program checkout:

Execution Speed Qi~g!!os!:i£§: Comprehensive dia9nostic messages are provided during both compilation and execution. In processing IDuring testing of the compiler with release an erroneous statement, the compiler may 120.1 of the operating system, the total CPU attempt to correct the error ry making an time during the execution steps of a sample assumption about the intention of the of scientifically-oriented programs that statement. Messages produced during had been optimized was 50% less than that compilation will be for errors in the of the same sample compiled by version 5 of categories of unrecoverable, severe error, the PL/I (F) Compiler with a range error, warning, and informatory. The of saving on individual jobs betw~en messages will be listed in category groups 0% and 63%. in ascending statement number order. Each

Chapter 1: The OS PL/I Optimizing Compiler 3 Page of GC33-0001-2 Revised June, 1913 By TNL: GN33-6095

message will indicate the number of the • Control progress into syntax checking erroneous statement and, when applicable, depending upon the severity of the the part of the statement involved, the diagnostics from previous processing. exact nature of the error, and any assumptions made and action taken by the • Control progress beyond syntax checking compiler. depending on the severity of the diagnostics from previous processing. ~lo~~ra£~: The flow trace facility can be used to produce a record of the changes in • Specify whether full or short diagnostic sequential flow prior to an interrupt. The messages are to be printed. trace is included as part of the diagnostic output produced by the SNAP option of the • List statement numbers of declarations ON statement or by the PLIDUMP built-in (if applicable) and all attributes . It contains a list of branch­ assigned to all identifiers in the out/branch-in pairs of statement numbers. program. The associated control name (up to 8 characters) is also given. The number of • List the external symbol dictionary. statements to be included in the flow trace is given by the user in requesting the • List implementation dependent option. This feature is in addition to the information (for example, the length of optional inclusion of the statement number structures). in diagnostic messages produced at E!xecution time. • Specify the number of lines to be printed on each page of output. 1§!:.~!:.~H1~!!t_:E~~g!!~!!£L£Q!!u!:,;iug: This facility lean be used to identify those parts of a • Print block-levels and do-levels on the I program that are most heavily used and source program listing. Ithose statements that are never used. The Istatement count is given at program • List the options used by the compiler. Itermination on the PLIDUMP file. If the IPLIDUMP file does not exist, SYSPRINT is • List the source program. lused. • specify the minimum severity level at Qn=Yn!!:.§: Program condition-handling is which source program diagnostic messages facilitated by the provision of on-units will be printed. for all PL/I conditions. On-units permit either programmer-defined or system-defined • List statement numbers of declarations action to take place when a particular and of statements in which reference is interrupt occurs during execution. The made to all identifiers in the program. range of conditions covers all arithmetic interrupts, input/output errors" and • specify that an object module is to be special program-checkout conditions such as produced in a form suitable for input to CHECK, SOBSCRIPTRANGE, STRINGRANGE, SIZE, the linkage editor. and STRINGSIZE. • specify that a NAME statement is to be produced for an object module.

• Indicate that the source program (~ompiler Options requires preprocessing. • List source input to the preprocessor. A number of compiler options are available for use by the programmer to specify • specify that the output from the information or to request optional compiler preprocessor is to be generated in a 1:acilities. card image format suitable for punching.

The options available may be used to: • Print the contents of registers and main storage in the event of compiler Q Specify whether the source program is failure. coded in the PL/I 48-character set or 60-character set, or punched in BCD or • specify the amount of main storage EBCDIC format. available for compilation.

• Specify the margins for source • specify whether statement numbers are to statements. be obtained by counting semicolons, or derived from line numbers. • Specify a margin indicator character for source statements. • specify that selected output from the

4 for a particular compilation. subroutines used must be called from the resident or transient library as - Specify that the output from the appropriate. compiler is to be generated in a card image format suitable for punching. • List the numbers of the last "nW Compatibility between Releases disc(,ntinuities (for example CALL or GO TO) executed prior to an interrupt. These numbers are included in the output Different release levels of the Optimizing produced by the SNAP option. Compiler and its libraries will produce compatible execution, provided that: • specify that diagnostic messages produced during execution are to contain 1. The release level of the transient source program line numbers. library is equal to or greater than that of the resident library. • Produce additional coding that will allow statement numbers from the source 2. The release level of the resident program to be included in messages library is equal to or greater than produced during execution. that of the compiler.

• Print tables showing the organization of static storage for the object module. Compatibility between OS and DOS • Print statement numbers for statements internal to each procedure with their offsets relative to the primary entry Because the OS Optimizing Compiler point of the procedure. implements more of the PL/I language than the DOS Optimizing Compiler, all source - specify optional optimization or not. programs compiled on the DOS Optimizing compiler can be compiled on the OS - Print a table giving the storage Optimizing Compiler, thus aiding the requirements for the object module. conversion from DOS to OS.

I- Count the number of times that I statements are executed. Interlanguage Communication I I- Indicate that the %INCLUD~ statement is I the only PL/I preprocessor statement Facilities are available which allow I used, permitting faster compilation procedures compiled by the Optimizing I without the use of the preprocessor. Compiler to communicate at execu,tion time I with programs compiled by any of the I- List the generated code for the whole following COBOL or FORTRAN compilers I program or for a specified range of produced by IBM for the operatinq' system. I statements. COBOL Compilers:

COBOL (E) Level E Compatibility with the (F) Compiler COBOL (F) Level F COBOL ANS(FULL) Level F Source programs written for version 5 of FORTRAN Compilers: the PL/I (F) Compiler can be compiled by the Optimizing Compiler and will be FORTRAN IV(Basic) Level E executed correctly without modification, FORTRAN IV Levels G and H except for a few minor differences between the implementations of the PL/I language Existing COBOL and FORTRAN uSI::!rs can for the two compilers. These differences write new applications in PL/I while still are described in appendix B. using existing libraries of COBOL and FORTRAN programs; in addition, existing Object modules produced by version 5 of applications can be modified by 1:he use of the PL/I (F) compiler, and modules from the PL/I procedures. PL/I (F) Compiler subroutine library, cannot be incorporated into programs Communication between PL/I programs and compiled by the optimizing compiler. All programs written in different languages is PL/I source modules must be recompiled with specified in the usual way, by a CALL the Optimizing Compiler, and all library statement. A FORTRAN program cml be called

Chapter 1: The OS PL/I Optimizing Compiler 5 a.lso by a function reference.

The interlanguage communication facilities are obtained by specifying I ASSEMBLER, COBOL, or FORTRAN as an option in a PROCEDURE, ENTRY, or DECLARE statement. (See "Interlanguage communication," in chapter 3.>

6 Chapter 2: Optimization

The main aim of the optimizing compiler is in the same value each time it is to generate object programs that can be evaluated, that is, an expression that is executed as fast as possible and that identical to another, with no intervening occupy as little space as possible during modification to any operand. The compiler execution. In many cases this will involve eliminates a common expression by saving generating efficient code for statements in the value of the first occurrence of the the sequence written by the programmer; in expression either in a temporary (compiler­ other cases, however, the compiler may generated) variable, or in the program alter the sequence of statements or variable to which the result of the operations to improve the performance while expression is assigned. For example: producing the same result. Xl = A1 * Bl; The following types of optimization are carried out by the compiler:

• Common expression elimination Yl = Al * Bl;

• Transfer of expressions from loops Provided that the values of Ai, Bl, and Xl do not change between the execut~ion of • Redundant expression elimination these statements, the statements: can be optimized to the equivalent of .he • Simplification of expressions following PL/I statements: • Initialization of arrays and structures Xl = Al * Bl;

• In-line code for conversions

• In-line code for RECORD I/O Yl = Xli

• Key handling for REGIONAL data sets If the first occurrence of the common expression involves the assignment of the • Matching format lists with data lists value to a variable that is modified prior to the occurrence of the later expression, • In-line code for string manipulation the value is assigned to a temporary variable. The example given above would • In-line code for built-in functions become:

• Special-case code for DO statements TEMP = Al * Bl; Xl TEMP; • Structure and array assignments

• Library subroutines Xl Xl + 2;

• Elimination of common constants Yl = TEMP; • Elimination of common control data Also, if the common expression occurs as a • Use of registers subexpression within a larger expression, a temporary variable is created to hold the • Code for program branches value of the common subexpression. For example, in the expression Cl + Al * Bl a temporary variable would be created to hold Common Expression Elimination the value of Ai * Bl if this were a common subexpression.

An expression can occur twice or more in An important application of this such a way that the flow of control always technique occurs in statements containing passes through the first occurrence of the subscripted variables where the same expression to reach a subsequent subscript value is used for each variable. occurrence. A common expression is an For example: expression that occurs more than once in a program but is obviously intended to result PAYTAX(MNO)=PAYCODE(MNO)*WKPMNT(MNO);

Chapter 2: Optimization 7 The value of the subscript MNO is computed The expression SQRT(N) can be moved once only when the statement is executed. out of the loop to a position where it ('rhe computation would involve the is possible for the expression to be conversion of a value from decimal to executed more frequently than it would binary if MNO were declared a decimal be in its original position inside the v,ariable. ) loop. This undesired effect of optimization can be prevented by the use of the ORDER option for the block in which the loop occurs. Transfer of Expressions from Loops

Where it is possible to produce error-free 2. Loops are detected by a flow-analysis execution without affecting the results of process. This process can fail to a program, the optimization process moves recognize a loop, owing to the invariant expressions or statements from existence of flowpaths which the inside a loop to a pOint which immediately programmer knows will never be used. precedes the loop. An expression or For example, the use of label statement occurring within a loop is said variables can inadvertently cause to be invariant if the compiler can detect optimization to be inhibited by making that the value of the expression or the the recognition of a desired loop action of the statement would be identical impossible. for each iteration of the loop. A loop can be either a do-loop or a loop in a program that can be detected by the analysis of the flow of control within the program. For Redundant Expression Elimination example:

DO I = 1 TO Ni A redundant expression is an expression B(I) = C(I) • SQRT(N); that need not be evaluated for a program to P = N • J; be executed correctly. For example, the END; logical expression:

This loop can be optimized to produce (A=D) I (C=O) object code corresponding to the following statements: contains the subexpressions (A=D) and (C=O), the second of which need not be TEMP = SQRT(N)i evaluated if the first is true. The effect P = N • J; of this optimization is to the use of DO I = 1 TO N; a compound logical expression in a single B(I) = C(I) • TEMP; IF statement more efficient than an END; equivalent series of nested IF statements.

If the programmer wishes this type of optimization to be carried out, he must specify the optimization option REORDER for Simplification of Expressions a BEGIN or PROCEDURE block which contains the loop. If the option is not specified, the default option, ORDER, is assumed, and Simplification of an expression involves optimization is inhibited. its conversion into a form that can be translated into more efficient object code. E,rogramming Considerations: Where applicable, multiplication and division operations are converted into 1. The transfer of expressions from addition and subtraction operations, which inside a loop is performed on the can be performed by faster machine assumption that every expression in instructions. For example: the loop is executed more frequently than expressions immediately outside DO I = 1 TO N BY 2; the loop. Occasionally this assumption fails, and expressions can be moved out of loops to positions ltlhere they are executed more A(I) I • 4; frequently than they would have been if they had remained inside the loop. 1?or example: END; DO I = J TO K WHILE(X(I)=O); XCI) Y(l) * SQRT(N); This loop can be optimized to produce END;

8 object code corresponding to the following Base(A) + TEMP for array A, and statements: Base(B) + TEMP for array B. I = 1; /* LOOP INITIALIZATION */ IF I > N THEN GO TO F; A loop control variable and its iteration TEMP = 4 * I~ specification can be optimized only when G: /* LOOP ENTRY POINT */ the control variable used as a subscript is incremented by a constant value. The value of the control variable must not be required outside the loop in which it is A(I) = TEMP; /* EXPRESSION AFTER */ specified. /* SIMPLIFICATION */

Defactorization I = I + 2; TEMP=TEMP + 8; IF I < N THEN GO TO G; Where possible, a constant in an array /* END-OF-LOOP TEST */ subscript expression is used as ,an offset F: /* LOOP EXIT POINT */ in the address calculation. For example, the address of a four-byte element: A(I+I0)

would be calculated as:

Modification of Loop Control Variables (Base(A)+4*10)+I*4.

Where possible, the expression­ simplification process will modify both the Replacement of Con~tant Expressions control variable and the iteration specification of a do-loop to achieve more efficient processing when the control The expression-simplification process variable is used as a subscript. The replaces constant expressions of the form calculation of addresses of array elements A+ B or A*B, where A and Bare in·teger can be made faster by replacing constants, with the equivalent constant. multiplication operations by addition For example the expression 2+5 is replaced operations. For example, the loop: by 1.

DO I 1 TO N BY 1; A(I) = B(I); END; Replacement of Con~tant Multiplil~rs and Exponents causes N element values from array B to be assigned to corresponding elements in array A. On the assumption that each element is The expression-simplification process four bytes in length, the address replaces certain constant multipliers and calculations used for each iteration of the exponents. For example: loop are: A*2 becomes A+A, Base(A)+(4*I) for array A, and and Base(B)+(4*I) for array B, A**2 becomes A*A. where RBaseR represents the base address of the array in storage. The repeated multiplication of the control variable by a constant representing the length of an Initialization of Arrays and Structures element can be converted to faster addition operations. The optimized DO statement above is converted into object code When arrays and some structures which have equivalent to the following statement: the BASED, AUTOMATIC, or CONTROLI~ED storage class are to be initialized by a constant DO TEMP = 4 BY 4 TO 4*N; specified in the INITIAL attribu1:e, the first element of the variable is The element address calculations are initialized by the constant, and the converted to the equivalent of: remainder of the initialization consists of

Chapter 2: Optimiza1:ion 9 a single move which propagates the value string are not reconverted to fixed binary. through all the elements of the variable. (This conversion would otherwise be For example: necessary to obtain the region number.>

DCL A(20,20) FIXED BINARY INIT«400)0): The array A would be initialized in this Matching Format Lists with Data Lists way. Where possible, format and data lists of edit-directed input/output statements are In-Line Code for Con versions matched at compile-time. This is possible only when neither list contains repetition factors that are expressions whose values Most conversions are performed by in-line are unknown at compile-time. This permits code, rather than by calls to the resident conversion to or from the data list item to or transient library. The exceptions are: be performed by in-line code. Also, on input the item can be taken directly from • Conversions between character and the buffer or on output placed directly in arithmetic data. the buffer. Library calls are eliminated except when it is necessary to transmit a • Conversions from numeric character block of data between the input/output (PICTURE) data where the picture device and the buffer, for example: includes characters other than 9, V, Z, or a single sign or currency cha.racter. DCL (A,B,X,Y,Z) CHAR(25); GET FILE(SYSIN) EDIT(X,Y,Z) (A(25»: • Conversions to numeric character PUT FlLE(SYSPRINT) EDIT(A,B) (A(25»; (PICTURE) data where the picture includes scale factors or floating point In this example, format list matching is picture characters. performed at ; at execution time, library calls will be required only For example, conversions to 'ZZ9V99' will when the buffer contents are to be be done in-line. transmitted to or from the input/outout device.

In-Line Code for Record I/O In-Line Code for String Manipulation For consecutive buffered files under certain conditions, the input/output Operations on many character strings (such transmission statements READ, WRITE, and as concatenation and assignment of LOCATE are implemented by in-line code adjustable, varying length, and fixed­ rather than by calls to the resident or length strings) are performed in-line. transient libraries. Similar operations on many aligned bit strings are performed by in-line code.

Key Handling for REGIONAL Data Sets In-Line Code for Built-In Functions In certain circumstances, key handling for regional data sets is simplified by Many built-in functions are executed by in­ avoiding unnecessary conversions between line code. INDEX and SUBSTR are examples fixed binary and character-string data of functions for which in-line code is types, as follows: usually generated. TRANSLATE, VERIFY, and REPEAT are examples where in-line code is REGIONAL(l): If the key is supplied as a generated for simple cases. fixed binary integer with precision (12,0) through (23,0), there is no conversion from fixed binary to character-string and back again. Special-Case Code for DO Statements REGIONAL(2) and REGIONAL(3): If the key is supplied in the form Kill, where K is a Where possible, for a do-loop, the character string and I is fixed binary with Optimizing Compiler will generate code in preC1S10n (12,0) through (23,0), the which the value of the control variable and rightmost eight characters of the resultant the values used in the iteration

10 specification are held in registers WEEK NO = WEEK NO + 1; throughout execution of the loop. For RECORD_COUNT =-RECORD_COUNT + 1; example, the compilerrwill attempt to maintain in registers the values of the the 1 is stored once only provided that variables I, K, and L in the following WEEK NO and RECORD COUNT have t:he same statement: attrIbutes. -

DO I = A TO K BY L;

This form of optimization permits the most efficient loop control instructions to be Elimination of Common Control Data used. The optimizing Compiler generat:es control information to describe certain program elements such as arrays. If there are two Structure and Array Assignments or more similar arrays, this de!scripti ve information is generated once only.

structure and array assignment statements are implemented by single move instructions whenever possible. Otherwise the Use of Registers assignment is performed by the simplest loop possible for the operands specified in the assignment. For example: More efficient execution of loc,ps can be achieved by maintaining in registers the DCL A(10),B(10), 1 S(10), 2 T, 2 U; values of variables that are su.bject to frequent modification during execution of A=B; the loops. When program flow clf control permits, values can be kept in registers, A=T; and considerable efficiency can be achieved by dispensing with time-consuming load-and­ The first assignment statement will be store operations to reset the values of implemented by a single move instruction, variables in their storage locations. If while the second will be implemented by a the latest value of a variable is known not loop, since array T is interleaved with to be required after a loop has been array U, thereby making a single move executed, the value is not assigned to the impossible. storage location of the variable when control passes out of the loop.

Register allocation can be more Library Subroutines significantly optimized if REORDER is specified for the block. However, the values of variables that are reset in the The resident and transient libraries have block are not guaranteed to be the latest been designed as sets of subroutines assigned values when a computational containing logically-related functions. interrupt occurs, since the latest value of These functions are distributed among the a variable may be present in a register but library subroutines in such a manner that a not in the storage location of the link-edited object program will contain variable. If ORDER is specified, only code likely to be necessary for the optimization of is functions used in that program. impeded by the requirement that all values of variables reset in the block are The groups of functions particularly guaranteed, and must therefore be assigned concerned with this efficient structuring immediately to the storage locations of include record-oriented input/output, their respective variables. stream-oriented input/output, conversions, and error handling. Code for Program Branches Elimination of Common Constants Base registers for branch instructions in the object program are allocated. in If a constant is used more than once in a accordance with the logical structure of program, a single copy of that constant is the program. This minimizes the occurrence kept. For example, in the following of program-addressing load instructions in statements: the middle of deeply nested loops.

Chapter 2: Optimization 11 Also, the branch instructions generated for IF statements are arranged by the compiler to be as efficient as possible. For example, a statement such asz IF condition THEN GOTO label; is defined by the PL/I language as being a test of the condition followed by a branch on false to the statement following the THEN clause. However, when the THEN clause consists only of a GOTO statement, the statement is compiled as a branch on true to the label specified in the THEN clause.

12 Chapter 3: The PL/I Language Implemented

New language features, together with a operations number of extensions to the language implemented by version 5 of the PL/I (F) Compiler, have been included in the • Assignment, with automatic cI::>nversion if language implemented by the optimizing necessary, between data vari.ables. compiler. A list of the PL/I keywords implemented by the new compiler is given in • Element, array, and structure appendix A. expressions. In general, a PL/I source program • Arithmetic, comparison, logical written for version 5 of the PL/I (F) (boolean), and string-manipulation Compiler will produce identical results operators. when compiled by the Optimizing Compiler. In a few cases, results may differ because • Built-in functions for mathematical and the Optimizing Compiler restricts some arithmetic computation, string language features to a different degree, manipulation, manipulation of based and and because there are minor controlled storage, manipulation of incompatibilities between the arr ays, mul titasking, and erlC'or implementations of the language by the two handling. compilers. The most significant differences in implementation restrictions • Pseudovariables for computation and are given in figure 1, and the error handling. incompatibilities are listed in appendix B. • Facilities for creating progl~ammer­ defined functions.

Language Features. Data Aggregates

The language implemented by the optimizing • Arrays of data elements compiler includes the following features: • Structures of data elements • Arrays of structures

Data Types Program Management • Character-string and bit-string data. • Preprocessing. • Fixed-point binary and fixed-point decimal data (real and complex). • separate compilation of extel~nal procedures of the same progrctm. • Floating-point binary and floating-point decimal data (real and complex). • Structuring of program into blocks to limit the of names and to permit • Character and (real and complex) decimal flexible allocation of storage. picture data. • Recursive invocations of a pl~ocedure • Label and entry data. with stacking and unstacking of generations of automatic datal. • File data. • Multitasking facilities. • Task and event data. • Maintenance of external procE~dures in • Pointer and offset data. auxiliary storage for dynamic loading into, and deletion from main storage • Area data. during program execution.

Chapter 3: The PL/ I Language Impleme~nted 13 Ir------, Feature I PL/I (P) Compiler I PL/I Optimizing Compiler I I I (Version 5) I J 1------.------I AREA size 32,168 16,111,216 Arrays, max. number of 32 15 dimensions Structures 63 levels 15 levels

Floating-point data short, long precision short, long, or extended~ decimal, binary and precision decimal, binary, and numeric character numeric character modes I modes I Factored attributes: INO limit max. number: 16 DECLARE statement I I Attribute factorization: I nesting levels Imax.number: 13 max. number: 16 I Block nesting Imax.depth: 50 max. depth: 50 2 I storage limitations: I STATIC INTERNAL maximum: 16M bytes No limit and AUTOMATIC string repetition factor maximum number of characters: 5 15 maximum value of factor: 16,310 32,161 Depth of nesting of max. number: 49 max. number: 2 descriptor list in ENTRY statement Identifiers in check list max. number: 510 limited only by size of statement Elements in data list I max. number: 320 max. number: 250 I Length of string in REPLY Imax.length: 100 max. length: 12 option of DISPLAY statement I

~ Facilities will be provided for the simulation of the extended" floating-point instruction set; the user can employ these simulation facilities should the system at his installation not contain the instruction set. 2 There is a limit on the depth of block nesting imposed by the length of the block labels given by the user. If the average length of the labels exceeds eight characters, the maximum number of available nesting levels is reduced. L------·------J Figure 1. Differences in implementation restrictions

• Dynamic storage allocation. internal and external forms of data representation. • processing of interrupts and error conditions. • Record-oriented input/output with both move and locate modes of operation. Input/Output • Sequential and direct-access processing modes. • stream-oriented input/output with • Message processing (teleprocessing) automatic conversion to and from mode.

14 • Asynchronous input/output data DEFAULT Statement transmission.

Identifiers which are declared with only a partial set of attributes,. or which are not explicitly declared, can derive: any other attributes required from two sources: Language Extensions The standard default attributes supplied by PL/l. Language features implemented by the optimizing Compiler that are only partially The default attributes specified in implemented or not implemented at all by a DEFAULT statement. version 5 of the PL/I CF) Compiler are described in outline below. A DEFAULT statement can supplement, but not override, the attributes of selected groups of:

Explicitly. contextually, or implicitly declared identifiers. Optimization Parameter descriptors in ENTRY descriptor lists. The Optimizing Compiler carries out extensive optimization of PL/I programs. Values returned by functions. Optimization is controlled by a compiler option and the use within the PL/I program If there is no DEFAULT statement, or if of the ORDER and REORDER options for a set of required attributes is still program blocks. Optimization is discussed incomplete after the DEFAULT statement has in chapter 2. been applied, a.ny attributes required are supplied by the standard defaults. The DEFAULT statement cannot be used to specify a structure, although the attributes of structure elements can have Program Checkout defaults applied according to a RANGE specification.

CHECK Condition Prefix: Variables External entry names cannot be specified specified in the name-list of the CHECK in a DEFAULT statement; they must be condition may be of any problem data type. declared explicitly. They must not be iSUB defined variables or explicitlY'-qualified based variables. They Note: A DEFAULT statement may .be given a may also be parameters. For example: label, but the label will be tr(~ated as if it were on a null statement. (CHECK CA,B,C,D»: F: PROC OPTIONS(MAIN); DCL A FIXED STATIC, B FLOAT AUTO, C CHARCI0) CONTROLLED, Preprocessing Facilities D FIXED DECIMAL BASEDCP);

CALL XeD); Assignment to Values: The RESC1\N and eCHECK(E»: NORESCAN options may be specifiE~d on X: PROCCE); %ACTIVATE and %DEACTIVATE staternents. The DCL E FIXED DECIMAL; NORESCAN option enables the pro~Jrarnmer to specify that an activated preprocessor iSUB Beyond Range: The SUBSCRIPTRANGE character-string variable or en1:ry name condition is raised when an iSUB variable appearing in the source text is to be is outside the range given in the replaced by its actual value; that is. the declaration of the iSUB-defined array. For usual rescanning process does not take example: place. If the RESCAN option is specified, the variable is activated as though no DCL A(24) CHAR(4), option were specified; rescanning takes B(5) CHAR(4) DEF A(4*lSUB); place at each replacement level. For example: SUBSCRIPTRANGE would be raised on reference to B (6). %DCL WRITE CHARACTER;

Chapter 3: The PL/I Language Implemented 15 ~WRITE = 'WRITE EVENT(E)'; • If used only once in such a structure, it need not be used with the last ~ACTIVATE WRITE NORESCAN; element.

WRITE FILE(F) FROM(X); • The REFER object need not be fixed binary. The WRITE statement will be modified to: For example: WRITE EVENT(E) FILE(F) FROM(X); DCL 1 X BASED, If the %ACTIVATE statement were omitted, 2 M, replacement of WRITE would continue 2 N, indefinitely, and the program would be 2 Y(10 REFER (M): meaningless. S REFER (N», 2 (I,J), LENGTH and INDEX: The LENGTH and INDEX 2 K, built-in functions may be used within a 3 A AREA(S REFER (I», preprocessor statement. 3 STR CHAR(L REFER (J» VAR, S FLOAT BINARY INIT(2000), L FIXED DECIMAL INIT(50);

Listing Control Statements Loading procedures dynamically: A procedure invoked by a CALL statement, by a CALL option of an INITIAL attribute, or by The listing control statements, %SRIP and a function reference, is normally resident IPAGE, allow the programmer to control the in main storage throughout the execution of formatting and line spacing of the printed the entire program. External procedures listing of his program. Although both (other than main procedures) may, however, these statements have the initial % sign, be maintained in auxiliary storage. Copies neither of them necessitates the use of the of such procedures can be dynamically preprocessor. loaded into, and deleted from, main storage as required by the program. Fetching and %PAG~: The statement following the %PAGE releasing of the procedures are initiated statement in the program listing is printed by the new PL/I statements, FETCH and on the first line of the next page. The RELEASE. The new feature is particularly statement is applied to both the insource use"fulwhen a called procedure is not listing (the input to the preprocessor) and necessarily invoked every time the calling the source listing (the preprocessed text). procedure is executed, and when conservation of main storage is important. %SKIP(n)]: The specified number of lines following a %SKIP statement in the program listing are left blank. nnw may be any integer from 1 through 99. Omission of a value for wnw is equivalent to specifying ENVIRONMENT Attribute the value of 1. The statement is applied to both the insource listing (the input to the preprocessor) and the source listing Changes and extensions to the options of (the preprocessed text). the ENVIRONMENT attribute specifying record format, block size, and record size, are as follows:

Storage Control Record format: (FIFBIFBSIUIVIVBIVBSIVSI DIDB] subscripted or Based Locator: The pointer Block size: [BLKSIZE(blocksize)] and offset variables associated with based variables can be subscripted, or based, or Record size: [RECSIZE(recordsize)] both. The ENVIRONMENT attribute need not self-defining structures: Many of the necessarily specify any of the above restrictions imposed by the PL/I (F) options. Missing information may be implementation of the REFER option have supplied in a data-set label, a DD been removed or modified in the language statement, or by default (at OPEN time'. implemented by the Optimizing Compiler. This means, for instance, that the The main changes are: programmer can specify record size in his source program while leaving specification • The REFER option can be used more than of block size until the program is actually once in a based structure. executed, when the I/O devices are known.

16 The Optimizing compiler will recognize used to create or access a data set with and convert the previously-implemented records of this type. During creation, the forms of the above options as shown below, length field is transmitted wit.h the and will issue a message stating that they string~ when being accessed, the first two are obsolete. bytes of the record are recogni.zed as a length field. Old form converted to For a non-element varying-length string, F(b) F BLKSIZECb) RECSIZE(b) for example, one that is an array or a F(b,r) F BLKSIZE(b) RECSIZE(r) member of a structure that is transmitted U(b) U BLKSIZE(b) RECSIZE(b) as a whole, the length field will always be V(b) V BLKSIZE(b) RECSIZE(b-4) transmitted both while being created and V(b,r) V BLKSIZE(b) RECSIZECr) while being accessed. VBS(b,r) VBS BLKSIZECb) RECSIZE(r) VS(b,r) VS BLRSIZECb) RECSIZE(r) The option must not be specified for use with varying-length string records in data There are two new data-set organizations, sets created by version 5 of the PL/I (F) TP(M) and TP(R), associated with Compiler, as this compiler neither creates teleprocessing. TP(M) implies the nor recognises such a length field. transmission of whole messages; TP(R) implies the transmission of records. Both are valid only for TRANSIENT files. These data-set organizations are equivalent to The SCAI,ARVARYING and CTLASA/CTL360 the options GCm) and R(r) available in options cannot be specified for the same version 5 of the PL/I (F) Compiler. The data set. optimizing Compiler will recognize and convert as follows:

Old form Converted to Record-Oriented Transmission G(m) V TP(M) RECSIZE(m) R(r) V TP(R) RECSIZE(r) Record I/O Statements: The record variable specified in an INTO or FROM option can be variables in Options: Whenever a numeric DEFINED, or a parameter, provided the value is required to complete the reference is to connected storage. The specification of an ENVIRONMENT option, the CONNECTED attribute is discusse~ later in value may be expressed as a decimal integer this chapter. The reference may be a constant or a static fixed binary variable structure or array which contains varying­ of precision (31,0). The variable, if length strings. For example: used, must be assigned a value before the file is opened. DCL A (10) CHAR (6) VAR, 1 B, REREAD Option: The REREAD option 2 C CHAR (3) VAR, backspaces a magnetic tape to the start of 2 D CHAR (16) VAR, the data set when the associated file is E(10) CHAR(6) DEFINElD A; closed. READ FILE (X) INTO (A); ASCII Option: The ASCII option specifies READ FILE (X) INTO (B); that American standard code for information WRITE FILE (X) FROM (E); interchange is used to represent data on the data set. CALL ZeAl; BUFOFF option: The BUFOFF option specifies Z: PROC (Y); the length of the block prefix fields that may be associated with records of an ASCII DCL Y (10) CHAR (6) VAR; data set. READ FILE (X) INTO (Y);

SCALARVARYING Option: When storage is allocated for a varying-length string variable, the Optimizing Compiler adds two ASCII Data Sets bytes, containing the current length of the string, to the declared length of the variable. The SCALARVARYING option Data sets on magnetic tape whos4~ data is determines how varying-length strings are represented in American standard code for transmitted to and from a data set. information interchange (ASCII) may be created and accessed by a PL/I program. The option must be specified when locate The implementation supports F, !i'B, U, D, mode statements (LOCATE and READ SET) are and DB record formats. F, FB, and U

Chapter 3: The PL/I Language ImplemE~nted 17 formats are treated in the same way as data Data Aggregates sets whose data is represented in EBCDIC (extended binary coded decimal interchange code). The 0 and DB formats are equivalent Array and Structure Operations: A to V and VB records. With the exception of reference can be made to both an array and the ENVIRONMENT attribute the same PL/I a structure in the same expression or program may be used to handle an ASCII data assignment provided that the target is an set as would be used for a data set in array of structures. EBCDIC form. (See, wENVIRONMENT Attribute W earlier in this chapter.)

Only character data may be written onto String Handling an ASCII data set. Varying-length strings cannot be transmitted to a data set using a SCALARVARYING file. Since an ASCII data STRINGSIZE Condition: If a string is set must be on magnetic tape it must be of assigned to a string shorter than itself, CONSECUTIVE organization. the source string is truncated on the right to the length of the target string, and the STRINGSIZE condition is raised. For example: File Names (STRINGSIZE): P: PROe; DCL A CHAR (20), File-Name Expressions: File names can be BeHAR (14); specified, in input/output statements, as B = Ai /* STRINGSIZE IS RAISED, A IS expressions: TRUNCATED ON ASSIGNMENT TO B */

For example: BASED or DEFINED with a VARYING Attribute: A variable declared with the BASED or DCL B(10) FILE, DEFINED attribute may also be given the X(Q) FILE; VARYING attribute. For example:

DCL e CHAR(10) BASED(P) VARYING, B CHAR(12) VARYING, GET FILE (FILEA) •••• ; D CHAR(12) VARYING DEFINED B; PUT FILE (B(6» •••• ; READ FILE (X(N*3» •••• ;

File-Name Constants and Variables: File Data Attributes names can be declared as file constants or file variables. An identifier is assumed The CONNECTED Attribute: This is a storage to be a file constant if: attribute of non-controlled data aggregate parameters. It specifies that the storage 1. It is declared with any file attribute associated with the aggregate is other than FILE. contiguous, that is, not interleaved with storage for other variables. This allows 2. It is not explicitly declared but the aggregate to be designated as a record appears in the FILE option of an variable or a base in string overlay input/output statement, or in an ON defining. For example: statement for an input/output condition. Q: PRoe (X,Y); DCL A FILE RECORD ENVIRONMENT It is assumed to be a file variable if: (F BLKSIZE(40)RECSIZE(40», X (10) CHAR (4) CONNECTED, 1. It has the FILE attribute and is an 1 Y CONNECTED UNALIGNED, element of a structure. 2 R, 2 S, 2. It has the FILE attribute and any of 3 T, the following additional attributes: 3 U, G CHAR (40) DEF X; STATICIAUTOMATICIBASEDICONTROLLED Dimension Parameter READ FILE (A) INTO (X); ALIGNED I UNALIGNED DEFI-NED INITIAL SUBSTR (G,28,8)= •••• ; VARIABLE

18 X and Yare entry constants. They can be WRITE FILE (A) FROM (X); explicitly declared with the ENTRY attribute only if external.

CALL B (Y); ~ni~Y_Y~~i~£1~: An identifier specified with the ENTRY attribute and any of the B: PROC (Z) RErURNS (DECIMAL); following attributes, which must be DCL 1 Z CONNECTED UNALIGNED, explicitly declared, is an entry variable. 2 RR, 2 SS, VARIABLE 3 TT, STATIC I AUTOMATIC I BASED I CONTROLLED 3 UU; Dimension Parameter ALIGNEDIUNALIGNED END Q; DEFINED INITIAL Igiti~li~~iiQ~_Qy_~~~~g~~i2~_2~_~g~£t12n: The initial value of a non-STATIC variable For example: declared with the INITIAL attribute can be derived from sources other than a constant. DCL X ENTRY (FIXED,BINARY,DECIMAL) The source may be an expression or a VARIABLE, function reference; on evaluation, the Y ENTRY (CHAR) AUTO, value derived is the initial value of the Z flO) ENTRY; variable. For example: Entry variables may be assigned, passed as DCL B AUTOMATIC INITIAL(F(X», arguments, and used in CALL statements and C INITIALCSQRT(3»; function references. variables and function references used in ~ni~y-~~mg2_~~g_~~~~~!£_~~m~2: rhe GENERIC these expressions must be known in the attribute has been altered to permit the block in which the initialized item is entry names specified in a generic declared. declaration to be dissociated from the generic name. The specification of an identifier as an alternative in a generic declaration does not constitute a declaration of the identifier; the occurrence of the identifier is regarded simply as an entry ~~~gssiQg that describes the entry name of the Where the extended precision feature is corresponding 2~Q£~Q~~~. For each entry available, the maximum precisions are: expression alternative, a descriptor list is specified by means of a WHEN clause. Binary floating-point data 109 Defaults are not applied to the descriptors in WHEN clauses. As a result the generic Decimal floating-point data 33 specification is much more flexible in that: The default precision for floating-point data remains as for version 5 of the PL/I 1. An identifier can be specified as more (F) Compiler, that is binary 21~ decimal 6. than one alternative in a GENERIC declaration, or in more than one GENERIC declaration.

2. The descriptor list need only partially describe the argument that must be matched in the generic There is greater flexibility in the use of reference. It can indicate that any entry names. An entry name can be either argument is acceptable. an entry constant or an entry variable. For example: §nt~Y_£Qg2~~~~: An identifier specified as a label prefix to a PROCEDURE or ENTRY DCL X GENERIC (A WHEN (FIXED, FIXED»; statement is an entry constant. For example: If the arguments to the generic reference X are both FIXED, then A is selected. If the X: PROC; specification had been

Y: ENTRY; A WHEN (,FIXED)

Chapter 3: The PL/I Language Implemented 19 R~~is~d J~~~, -1973- By TNL: GN33-6095 then any type of argument would be Ml = Z (Ll,L2); /* A IS SELECTED ./ acceptable as the first argument, but the M2 = Z (Ll,M2); /. NO MATCHING ARGUMENT, second would have to be FIXED. NO SELECTION. PROGRAM IS ERRONEOUS./ Generic selection is performed thus: Ml = Z (M2,S); /* B IS SELECTED */ 1. The alternatives are scanned from left to right until a WHEN clause is found which matches the arguments in the generic reference. "Matching" occurs when there are the same number of descriptors in the WHEN clause as New mathematical built-in functions, there are arguments, and when each ASIN(x) and ACOS(x)~ are available for descriptor in the WHEN clause computing arc sines and arc cosines. Only specifies a subset of the attributes real arguments are allowed. of the corresponding argument.

2. The entry expression in the alternative that contains the appropriate WHEN clause is then invoked with the arguments in the generic reference. The invocation may The = and A= operators may be used to involve the conversion of arguments compare any data type other than area, and the creation of dummy arguments. condition, event~ or task type. For example:

DCL X GENERIC (A WHEN (FIXED,FLOAT), A WHEN (FIXED,FIXED), B WHEN (FLOAT~COMPLEX», Y GENERIC (A WHEN (FLOAT, FLOAT) " ~h~_Qf~JQ~§_~~~f!£~~e/Q2~!Qn: The A WHEN (,FLOAT) " interlanguage communication facilities are C WHEN ( , ) ) , requested in a PL/I procedure by specifying Z GENERIC (A WHEN (FIXED"FIXED), the COBOL or FORTRAN option in the B WHEN (FLOAT,COMPLEX», PROCEDURE or ENTRY statement or in the (Ll,L2) FIXED, OPTIONS attribute in a DECLARE statement. (Ml,M2) FLOAT, I OPTIONS (ASSEMBLER) can be specified in a S COMPLEX; IDECLARE statement.

The rema~ping of COBOL structures, and CALL X (Ll,Ml); /* A IS SELECTED */ the transposing of FORTRAN arrays, can be CALL X (Ll,L2); /* A IS SELECTED */ completely or partially suppressed by the CALL X (M2,S) ; /* B IS SELECTED */ NOMAP~ NOMAPIN, or NOMAPOUT options. CALL X (Ml,M2); /* NO MATCHING ARGUMENTS, NO SELECTION. The INTER option is used to specify that PROGRAM IS ERRONEOUS*/ the assembler-language, COBOL and FORTRAN CALL Y (Ml,M2) ; /* A IS SELECTED */ interrupts that would normally be handled CALL Y (Ll,Ml); /* .A IS SELECTED */ by the operating system are to be handled CALL Y (S,Ll) ; /* C IS SELECTED */ by the PL/I interrupt handling facilities.

20 r~y~ UL U~JJ-UUU~-~ Revised June, 1973 By TNL: GN33-6095

Chapter 4: System Requirements

Machine Requirements given in the publication §y§~~m Generatign, Order No. GC28-6554.

COMPILATION

The minimum machine requirements for the os PL/I optimizing compiler are supplied by an AUXILIARY STORAGE IBM System/360 Model 40 with a main storage capacity of 128K bytes. The compiler will operate in a 50K partition Direct-access storage space is required in

I under MFT., in a 52K region under MVT 1, or in the link library for the optimizing la 72K region with the Time sharing option compiler and its libraries as follows: I (TSO). Under VSl and VS2, the partition or Iregion sizes are rounded up to a multiple I- Compiler: approximately 430 tracks on lof 64K. The compiler will also operate I a 2311, 240 tracks on a 2314, or 130 lunder the control of the Conversational I tracks on a 3330. IMonitor System (CMS) of the Virtual Machine I IFacility/370 (VM/370) and needs 320K bytes I- Resident library: approximately 60 lof virtual storage for the CMS virtual I tracks on a 2311, 33 tracks on a 2314, I machine. I or 20 tracks on a 3330. I The of the I- Transient library: approximately 60 machine must have the decimal and floating­ I tracks on a 2311~ 31 tracks on a 2314, point instruction sets. If timing I or 18 tracks on a 3330. information is required. the central processing unit must have the timer The Optimizing Compiler requires feature~ and use of this feature must be direct-access storage space for working­ specified at system generation. storage only when adequate main storage is not available. The amount required depends upon the size of the source program and the amount of main storage available to the EXECUTION compiler. The data set identified by SYSUT1 is used for this auxiliary storage. This data set is also used when the IThe storage requirements, either real or preprocessor is invoked and when the PL/I Ivirtual. for the execution of a PL/I 48-character set is used in the source Iprogram compiled by the optimizing compiler program. Idepend on the size and content of the Isource program. The real storage Irequirements may be reduced either by the luse of the VS1 or VS2 control programs or Iby use of the overlay facilities for INPUT/OUTPUT DEVICES Ihandling segmented object programs.

The machine must have the decimal At compile time and during subsequent link­ instructi on set.. Where the extended editing, devices are required for the precision floating point feature is following types of input/output: available it must have also the floating­ point instruction set. If timing Source program input information is required, the machine must have the timer feature, and use of this Printed listings feature must be specified at system generation. (If the DELAY statement is Object module in relocatable format used, the ability to handle the interval timer from the application program must Object module in relocatable card-image also be specified at system generation.) If format the DATE built-in function is used, the os control program should have date facilities The ddname associated with a particular incorporated at system generation. class of compiler input/output, and the permitted device types for each, are shown Full details of system generation are in figure 2.

Chapter 4: system Requirements 21 Re~ised June~ 1973 By TNL: GN33-6095

r------,Function I ddname I Device Type I When Required Input SYSIN DASD Always Magnetic tape Card reader Paper-tape reader Print SYSPRINT DASD Always Magnetic tape Printer Output to SYSLIN DASD When link-editing Linkage Editor Magnetic tape follows compilation in the same job. output to SYSPUNCH DASD When link-editing Linkage Editor Magnetic tape takes place in a (card deck) Card Punch subsequent job.

Compiler Spill SYSUTl DASD When adequate main File storage is not available

Source SYSLIB DASD When preprocessor statement %INCLUDE is used with Library either MACRO or INCLUDE l------______------Joption

Figure 2. Compiler input/output devices

Operating System Requirements M~!t!P!Qg!~mm!ng_~!£b_~_Var!~Q!~_llYmbe!_of Tasks (MVT): The number of tasks that can be-processed at anyone time is determined The Optimizing Compiler is a component of by the number of regions (segments of main the IBM Operating system. The control storage) plus the number of tasks created programs that the compiler will run under, dynamically in all the regions. Each and the data management facilities that may region is associated with a task and with be required~ are detailed below. all the subtasks it creates dynamically. Each task receives a share of the resources; subtasks use the resources allocated to the task that created them. CONTROL PROGRAMS l~i!£~~!_§~Q!~g~_lY2~1: This control Iprogram is the virtual-storage equivalent The Optimizing Compiler can be used lof the MVT control prcgram described above. under the following control programs: lIn general, a source ~rogram that compiles land executes successfully under MVT will do ~~!~iprQiramm!n~_wi~h_~_f!~~9_n~mQ~!_Q! Ithe same under VS2. Tasks (MFT): The number of tasks that can be processed at anyone time is determined Other operating system options under by the number of partitions (segments of which the compiler can run are: main storage) that exist at that time. Each task is associated with one partition, !im~_2h~!!ng_QE~!Qn_J~§QL: This option is and receives a share of the available available only to MVT or Vs2 users and resources. requires a region approximately 20K bytes larger than for MVT. The option provides: IY!!£g~!_~torag~_1~2!1: This control Iprogram is the virtual-storage equivalent • The ability to use subcommands that lof the MFT control program described above. allow interaction with a PL/I program lIn general, a source program that compiles during processing. tand executes successfully under MFT will do I; the same under VS1. • Facilities for several users to share a I' region of main storage for the I The PL/I multitasking facilities should concurrent execution of their programs. ~not be used under an MFT or vsl control Each terminal in session is granted program. exclusive use of the region for a series

22 Page of GC33-0001-2 Revised June, 1973 By TNL: GN33-6095

of short time slices. SM1) and pass records to be sorted, or receive sorted records~ or both pass and Mul~!E~2£~2!ng_1M&2~~L: Provides support receive records. for multiprocessing with two Model 658.

IConversational Monito!_~~2~~m_l~2L: see lappendix D for further details. CHECKPOINT/RESTART FACILITIES

The PL/I program may contain a statement to DATA MANAGEMENT FACILITIES invoke the checkpoint facility to record the current status of a program and its data in auxiliary storage. The checkpoint Object programs compiled by the optimizing data can be used by the restart facility to compiler make use of the operating system restart the program at the point in data management facilities. These execution when the checkpoint was taken. facilities are dependent on the I/O statements used and include: Basic Sequential Access Method (BSAM) System/370 Facilities Queued Sequential Access Method (QSAM) IThe following control programs, operating Basic Indexed sequential Access Method I systems, input/output devices, and access (BISAM) method can be used only with System/370:

Queued Indexed Sequential Access Method VS1 (Virtual Storage) control program. (QISAM) VS2 (Virtual Storage) control program. Basic Direct Access Method (BDAM) Conversational Monitor System (eMS). Telecommunication Access Method (TCAM) The 3330 Direct-Access Storage Device. Virtual Storage Access Method (VSAM) The 3505 Card Device. The 3525 Card Device. SORT FACILI'I'IES VSAM (Virtual Storage Access Method).

The PL/I program may contain statements to The availability of the optimizing invoke the operating system Type 1 compiler with these features is stated in sort/Merge program (360S-SM-023) or the the publication IBM-E!Qg~~!!L~!Qf!uct~2!gn program product Sort/Merge program (5734- QQj~ct!Y~2' Order No. GC33-0036.

Chapter 4: System Requirements 23

Appendix A: Keywords and their Abbreviations

The following is a complete list of the PL/I and implementation-defined keywords implemented, with exceptions, by both the OS PL/I optimizing Compiler and the OS PL/I Checkout Compiler. The keywords not implemented by the Optimizing compiler are indicated by an asterisk. Each of the keywords is described in detail in the publication OS PL/I Checkout and optimizing Compilers: Language Reference Manual.

Reyword Abbreviation Us~ of Keyword

A[ (w)] format item ABS ex) built-in function ACOSex) built-in function %ACTIVATE %ACT preprocessor statement ADDex1,x2,x3['x~]) built-in function ADD BUFF option of ENVIRONMENT attribute ADDRex) built-in function ALIGNED attribute ALL [e character- option of PUT statement string-expression)] * ALL ex) built-in function ALLOCATE ALLOe statement ALLOCATIONex) ALLOCN built-in function ANY ex) built-in function AREA condition AREA [ (size)] attribute ARGn option of NOMAP, NOMAPIN, NOMAPOUT options ASCII option of the ENVIRONMENT attr:ibute ASINex) built-in function I ASSEMBLER ASM option of OPTIONS option/attribute ATANex1.[,x2]) built-in function ATAND e Xd. [ , X2] ) built-in function ATANHex) built-in function ATTENTION * ATTN condition AUTOMATIC AUTO attribute B [ ew) ] format item BACKWARDS attribute, option of OPEN statt:!ment BASED [elocator- attribute expression) ] BEGIN statement BINARY BIN attribute BINARyex1.[,x2[,x3]]) BINex1.[,x2[,x3]]) built-in function BIT [elength)] attribute BITex1.[,x2]) built-in function BLKSIZEeblock-size) option of ENVIRONMENT attributE~ BOOLex1.,X2,X3) built-in function BUFFERED BUF attribute BUFFERS en) option of ENVIRONMENT attributt~ BUFOFF [ (n) ] option of ENVIRONMENT attributE~ BUILTIN attribute BY option of DO statement, option of repetitive input/output specification BY NAME option of assignment statement C(real-format-item format item [,real-format-item]) CALL statement, option of INITIAL a1:.tribute CEIL(x) built-in function CHAR (X1. [, X2 ] ) built-in function CHARACTER[(length)] CHAR [( length)] attribute CHECK * statement CHECK[(name-list)] condition, condition prefix CLOSE statement

Appendix A: Keywords and their Abbreviat:ions 25 Abbreviation Use of Reyword

COBOL option of ENVIRONMENT attribute, or OPTIONS option/attribute COLUMN(n) COL(n) format item COMPLETION (x) CPLN(x) built-in function, pseudovariable COMPLEX CPLX attribute COMPLEX(x~,x2) CPLX(x1,x2) built-in function, pseudovariable CONDITION COND attribute CONDITION (name) COND(name) condition CONJG(x) built-in function CONNECTED CONN attribute CONSECUTIVE option of ENVIRONMENT attribute "CONTROL * listing control statement CONTROLLED CTL attribute CONVERSION CONV condition, condition prefix COPY[(file-expression)] option of GET statement COS (x) built-in function COSD (x) built-in function COSH(x) built-in function COUNT (file-expression) built-in function CTLASA option of ENVIRONMENT attribute CTL360 option of ENVIRONMENT attribute D option of ENVIRONMENT attribute DATA option of GET or PUT statement DATAFIELD built-in function DATE built-in function DB option of ENVIRONMENT attribute "DEACTIVATE %DEACT preprocessor statement DECIMAL DEC attribute DECIMAL(x~[,x2[,x3]]) DEC(x1[,x2[,x3]]) built-in function DECLARE DCL statement "DECLARE %DCL preprocessor statement DEFAULT DFT statement DEFINED DEF attribute DELAY statement DELETE statement DESCRIPl'ORS option of DEFAULT statement DIM(x~,x2) built-in function DIRECT attribute DISPLAY statement DIVIDE(x1,x2,x3[,x4]) built-in function DO statement, repetitive input/output data specification "DO preprocessor statement E(w,d[,s]) format item EDIT option of GET or PUT statement ELSE clause of IF statement "ELSE clause of %IF statement EMPTY built-in function END statement "END preprocessor statement ENDFILE(file-expression) condition ENDPAGE(file-expression) condition ENTRY attribute, statement ENVIRONMENT ENV attribute, option of CLOSE statement ERF(x) built-in function ERFC(x) built-in function ERROR condition EVENT attribute, option of CALL, DELETE, DISPLAY, READ, REWRITE, and WRITE statements EXCLUSIVE EXCL attribute EXIT statement EXP(x) built-in function

26 EXTERNAL EXT attribute

, [ , F (W r d [, s] ] ) format item F option of ENVIRONMENT attribut:e FB option of ENVIRONMENT attribute FBS option of ENVIRONMENT attribut:e FETCH statement FILE attribute FILE (file-expression) option of CLOSE, DELETEw GET, LOCATE, OPEN, PUT, READ, REWRITE, UNLOCK, and WRITE statements FINISH condition FIXED attribute FIXED(x1[,x2[,x3]]) built-in function FIXEDOVERFLOW FOFL condition, condition prefix FLOAT attribute FLOAT (X1 ["X2] ) built-in function FLOOR (x) built-in function FLOW1 statement, option of PUT statement FORMAT statement, option of %CONTROL statement FORTRAN option of OPTIONS option/attribute FREE statement FROM (variable) option of WRITE or REWRITE statements FS option of ENVIRONMENT attribut:e GENERIC attribute GENKEY option of ENVIRONMENT attribute GET statement GO TO GOTO statement %GO TO %GOTO preprocessor statement HALT1 statement HBOUND(x1,x2) built-in function HIGH(x) built-in function IF statement "IF preprocessor statement IGNORE(n) option of READ statement IMAG(x) built-in function, pseudovariable IN (element-area-variable) option of ALLOCATE and FREE statements %INCLUDE preprocessor statement INDEX(x1,x2) built-in function INDEXAREA [(index- option of ENVIRONMENT attribute area-size)] INDEXED option of ENVIRONMENT attribute INITIAL INIT attribute INPUT attribute, option of OPEN stat~ement INTER option of OPTIONS option/attribute INTERNAL INT attribute INTO (variable) option of READ statement IRREDUCIBLE IRRED attribute KEY (file-expression) condition KEY (x) option of READ, DELETE, and REWRITE statements KEYED attribute, option of OPEN statement KEYFROM(x) option of WRITE statement KEYLENGTH(n) option of ENVIRONMENT attribute KEYLOC(n) option of ENVIRONMENT attribute KEYTO(variable) option of READ statement LABEL attribute LBOUND(x1,x2) built-in function LEAVE option of ENVIRONMENT attribute LENGTH (x) built-in function LIKE attribute LINE(n) format item, option of PUT statement LINENO(x) built-in function LINESIZE(expression) option of OPEN statement

Appendix A: Keywords and their Abbreviations 27 ~Q~~ ~~ U~JJ-VVV~-~ Revised June~ 1973 By TNL: GN33-6095

Q§.~ of_!S~Y~Q~g LIST option of GET or PUT statement ]~OCATE statement J~OG (x) built-in function LOG2(x) built-in function ['OG10(x) built-in function LOW(x) built-in function l"1AIN option of OPTIONS option r>1AX (X:l., X2 ••• xn) built-in function l"1IN (X:l., X2 ••• xn) built-in function 1>10D (X:l., X2) built-in function MULTIPLY(x:l.~X2~X3[IX~]) built-in function NAME(file-expression) condition NCP(n) option of ENVIRONMENT attribute I~OCHECK * statement NOCHECK [(name-list)] condition prefix iNOCONVERSION NOCONV condition prefix NOFIXEDOVERFLOW NOFOFL condition prefix NOFLOW * statement NOFORMAT option of %CONTROL statement NOLOCK option of READ statement NOMAP[(arg-list)] option of OPTIONS attribute NOMAPIN[(arg-list)] option of OPTIONS attribute NOMAPOUT[(arg-list)] option of OPTIONS attribute NOOVERFLOW NOOFL condition prefix NORESCAN option of %ACTIVATE statement NOSIZE condition prefix NOSTRINGRANGE NOSTRG condition prefix NOSTRINGSIZE NOSTRZ condition prefix NOSUBSCRIPTRANGE NOSUBRG condition prefix NOUNDERFLOW NOUFL con'dition prefix NOWRI'I'E option of ENVIRONMENT attribute NOZERODIVIDE NOZDIV condition prefix NULL built-in function OFFSET[(area-name)] attribute OFFSET (X:l.,x2 ) built-in function ON statement ONCHAR built-in function, pseudovariatle ONCODE built-in function ONCOUNT built-in function ONFILE built-in function ONKEY built-in function ONLoe built-in function ONSOURCE built-in function, pseudovariable OPEN statement OPTIONS(list) attribute, option of ENTRY and PROCEDURE statements ORDER option of BEGIN and PROCEDURE statements OUTPUT attribute, option of OPEN statement OVERFLOW OFL condition, condition prefix P 'picture specification' format item PAGE format item, option of PUT statement %PAGE listing control statement PAGESIZE(w) option of OPEN statement I PASSWORD option of ENVIRONMENT attribute PENDING (file-expression) condition PICTURE PIC attribute POINTER PTR attribute POINTER (X:l.,X2) PTR(x:l.,X2) built-in function POLY(x:l."x2) built-in function POSITION (expression) POS (expression) attribute PRECISION (X:l.,X2[,X3]) PREC(x:l.,X2[,X3 ]) built-in function PRINT attribute, option of OPEN statement PRIORITY(x) option of CALL statement PRIORITY [ (x)] built-in function, pseudovariable

28 PROCEDURE PROC statement %PROCEDURE %PROC preprocessor statement PROD(x) built-in function PUT statement R(x) format item RANGE option of DEFAULT statement READ statement REAL attribute REAL(x) built-in function, pseudovariable RECORD attribute, option of OPEN statement RECORD (file-expression) condition RECSIZE(record-length) option of ENVIRONMENT attribute RECURSIVE option of PROCEDURE statement REDUCIBLE RED attribute REENTRANT option of OPTIONS option REFER (element-variable) option of BASED attribute REGIONAL(1121 3 ) option of ENVIRONMENT attributE~ RELEASE statement REORDER option of BEGIN and PROCEDURE statements REPEAT(x1 ,X2) built-in function REPLY(c) option of DISPLAY statement REREAD option of ENVIRONMENT attribute RESCAN option of %ACTIVATE statement RETURN statement, preprocessor statement RETURNS (attribute-list) attribute, option of PROCEDURE statement REVERT statement REWRITE statement ROUND(x1,x2) built-in function SCALARVARYING option of ENVIRONMENT attribute SEQUENTIAL SEQL attribute SET (locator-variable) option of ALLOCATE" LOCATE, and READ statements SIGN (x) built-in function SIGNAL statement SIN (x) built-in function SIND(x) built-in function SINH{x) built-in function SIZE condition SKIP [ en) ] format item, option of GET and PUT statements %SKIP listing control statement SNAP * option of ON and PUT statements SQRT(x) built-in function STATIC attribute STATUS (x) built-in function, pseudovariable STOP statement STREAM attribute, option of OPEN statement STRING(x) built-in function, pseudovariable STRING (string-name) option of GET and PUT statements STRINGRANGE STRG condition, condition prefix STRINGSIZE STRZ condition, condition prefix iSUB dummy variable of DEFINED attribute SUBSCRIPrRANGE SUBRG condition SUBSTR(x1,x2[,x3]) built-in function, pseudovariable SUM (x) built-in function SYSIN name of standard system input file SYSPRINT name of standard system output option of ON or DECLARE statements TAN (x) built-in function TAND{x) built-in function TANH (x) built-in function TASK attribute, option of OPTIONS option TASK[(task-name)] option of CALL statement

Appendix A: Keywords and their Abbreviations 29 Page of GC33-0001-2 Revised June, 1973 By TNL: GN33-6095

'rHEN clause of IF statement :ITHEN clause of %IF statement 'rIME built-in function 'rITLE (element-expression) option of OPEN statement 'ro option of DO statement, option of repetiti input/output specification 'TOTAL option of ENVIRONMENT attribute 'TP(M I R) option of ENVIRONMENT attribute TRANSIENT attribute TRANSLATE(x~,x2[,x3]) built-in function TRANSMIT(file-expression) condition 'TRKOFL option of ENVIRONMENT attribute 'TRUNC(x) built-in function U option of ENVIRONMENT attribute UNALIGNED UNAL attribute UNBUFFERED UNBUF attribute, option of OPEN statement UNDEFINED FILE UNDF condition (file-expression) (file-expression) UNDERFLOW UFL condition, condition prefix UNLOCK statement UNSPEC(x) built-in function, pseudovariable UPDATE attribute, option of OPEN statement V option of ENVIRONMENT attribute VALUE option of DEFAULT statement VARIABLE attribute VARYING VAR attribute VB option of ENVIRONMENT attribute VBS option of ENVIRONMENT attribute VERIFY(x.1.,x2) built-in function VS option of ENVIRONMENT attribute \VSAM option of ENVIRONMENT attribute WAIT statement WHEN (generic- option in GENERIC declaration descriptor-list) WHILE option of DO statement WRITE statement X(w) format item ZERODIVIDE ZDIV condition, condition prefix

30 Appendix: B: Compatibility with (F) Compiler

Some features of the PL/I optimizing belonging to other variables. compiler implementation are incompatible with version 5 of the PL/I (F) Compiler • The ALLOCATION built-in func,tion returns implementation. The most significant a fixed-binary value giving 'the number incompatibilities are listed below. Except of generations of the argument that where stated, the description given is of exist in the current task. the optimizing Compiler implementation. Programs which were written for the (F) • The NULLO built-in function is not compiler and which use any of these implemented in the Optintizin.g Compiler. features should be reviewed before The NULL built-in function can be used compiling them with the optimizing Compiler for offset variables as well as for to ensure that they will return the same pointer variables. results. • The PROD built-in function accepts These, and other differences, are also arguments that are arrays of either given in the programmer·s guide for this fixed-point or floating-point elements. compiler. This general information manual The value returned has the same scale as also gives some of the implementation the argument given, except for limitations and restrictions of this fractional fixed-point argum(~nts for compiler. The language refer~nce manual which the result is in floating-point. for this compiler gives full details of the implementation of each language feature. • The SUBSTR built-in function returns a non-varying string.

• The SUM built-in function accepts arguments that are arrays of either fixed-point or floating-point elements. The value returned has the same scale as The (F) compiler holds the length of an the argument given. area in the first 16 bytes of the area. The optimizing compiler holds the length of the area in a descriptor outside the area. The DISPLAY Statement

Arrays and structures • The maximum length of the reply is 72 characters.

• The maximum number of dimensions in an array is 15. Dumps from PL/I Programs • The maximum depth of a structure is 15.

• The object-time dump facility of the (F) compiler, IHEDUMP, requires a DO Built-In Functions statement with the ddname PL1DUMP. Its equivalent in the Optimizing Compiler, PLIDUMP, requires a DO statement with • Built-in functions are recognized on the the ddname PLIDUMP. The optimizing basis of context only, so that all Compiler will attempt to use PL1DUMP if programmer-defined external procedures PLIDUMP is not available. must be declared explicitly. Built-in functions without arguments, such as TIME and DATE, must also be declared explicitly with the BUILTIN attribute, Entry Names, Parameters, and Returned or contextually with a null argument Values list, for example: TIME().

• For a variable to be a valid argument to • In general, an entry name in parentheses the ADDR built-in function it must be causes a dummy variable to bE' created; connected and its left extremity must for the function to be invoked, a null not lie within bytes that contain data argument list is required. However, an

Appendix B: Compatibility with (F) Compiler 31 entry name argument in parentheses, or LIKE Attribute an entry name without arguments, will be invoked if passed to a procedure whose parameter descriptor for the • The Optimizing Compiler does not permit corresponding argument specifies an a substructure to have the LIKE attribute other than ENTRY. attribute when another substructure within the major structure is the object • External entry names must always be of a further LIKE attribute. For explicitly declared. example:

• Area and string extents in the RETURNS DCL 1 A LIKE C, attribute or option must be represented 1 B, by a decimal integer constant. 2 C, 3 0, • The maximum depth of nesting in a 3 E, descriptor list in the ENTRY attribute 2 (F) LIKE X, is 2. 1 X, 2 Y, • An aggregate expression involving 2 Z; strings may not be passed as an argument unless there is a corresponding In this example, the structure A has the parameter descriptor in which all string LIKE attribute which refers to ~ubstructur~ lengths are specified as decimal integer C in structure B. B also contuins constant::;. substructure (F) with the LIKE attribute.

• An internal entry constant cannot be declared in a DECLl·,EE statemer~t. REDUCIBLE and IRREDUCIBLE may b€ specified on PROCEDURE and ENTRY statements. A scalar cannot be passed t.o an array parameter of an internal Link-Editing E'ntry constant if the parameter' s bounds are specified by asterisks. • Programs compiled by the optimizing compiler cannot be link-edited with object modules produced by the PL/I (F) compiler. The ENVIRONMENT Attribute

• For changes in the ENVIRONMENT attribute see "The ENVIRONMENT Attribute" in operating system Facilities chapter 3.

• The operating system facilities for sorting, for checkpoint/restart, for generating a return code, and for obtaining a dump are all invoked by means of a CALL statement with the dpproprjate entry-point name; tor • The error corrcc~ion logic differ9 from l'xdIT.f;le CALL PLISRTt.. 'Tne entry-puinl.. tJ:at used by th(; PL/I (F) --:ompilcr. names, which are listed below, have the Invalid programs that are compiled and BUILTIN attribute and need not be corrected by the (F) compiler may not declared explicitly. give the same results on the optimizing cornriler.

sort PLISRTx Checkpoint/Restart PLICKPT PLIREST PLICANC Return Code PLIRETC • ']~he limitations on the length of DECLARE Dump PLIDUMP statements impose some restrictions on t:he use of the INITIAL attribute. These The Optimizing Compiler does not restrictions are described under recognize the entry names used by the PL/I '''Statement Length" later in this (F) compiler, that is, IHESRTx, IHESARC, section. IHETSAC, IHEDUMx, IHECKPx, and IHERESx.

32 Page of GC33-0001-2 Revised June, 1973 By TNL: GN33-6095

if the condition (A=D) is satisfied, the condition (C=D) is ignored. This latter condition, however, might contain a • Sterling picture data is not function, which if not evaluated# could implemented. Therefore the following give rise to error. picture characters are not allowed:

G , H, M" P, 6, 7, 8 •

The PL/I(F) compiler return code facility (IHESARC or IHETSA) allowed values greater than 999 to be set. The • Text replaced by preprocessor statements optimizing compile~facility (PLIRETC) does not have blanks appended to either allows a maximum of 999 to be set. All end of the replacement value. values above this limit are reduced to 999 and a warning message issued. • A parameter descriptor list is not allowed in the declaration of a preprocessor variable with the ENTRY attribute.

• The RETURNS attribute may not be specified in a preprocessor DECLARE • The Optimizing Compiler does not statement. implement the REWIND option. Programs that use this option should be modified. Note that the function of the REREAD option implemented by the Optimizing Compiler is different from that of the REWIND option. The main difference is that the REREAD option over~ides any • For a varying string# the first 16 bits DISP parameter and controls the of the value of the UNSPEC positioning of the magnetic tape volume, pseudovariable represent the current whereas the REWIND option specifies that length of the string. the DISP parameter is to control the positioning of the magnetic tape volume • The pseudovariables COMPLETION, COMPLEX, according to the subparameter specified. PRIORITY# and STRING are not allowed as the control variable of a DO statement.

• The approximate maximum number of statements in a program is 10,000.

• READ J REWRITE, and DELETE statements are invalid for REGIONAL DIRECT OUTPUT files.

• There is no default record format for RECORD files. If the record format is not specified, the UNDEFINEDFILE • A label on a DECLARE statement is condition is raised. treated as if it were on a null statement.

• The process of eliminating redundant expressions could give rise to an • The optimizing compiler has a incompatibility for programs written for restriction that any statement must fit the PL/I (F) compiler that are into the work area of the compiler. The recompiled by the optimizing compiler. maximuIT size of this work area varies For example~ in the expression: with the amount of space available to the compiler. The limitations on the IF (A=D) I (C=D) THEN ••• length of statements are:

Appendix B: Compatibility with (F) Compiler 33 page o~ ~c~~-uuu~-~ Revised June~ 1973 By TNL: GN33-6095

50K - 60K 1012 characters • A filemark (or end of string mark for 61K - 78K 1600 characters the STRING option) is a valid item Over 78K 3400 characters delimiter for list- and data-directed input. An item thus delimited is processed intact, and ENDFILE (ERROR for Under VS1 or VS2 or when the 3330 is string) is raised on attempting to read used for the spill file the limitations a further item from the file or string. on the length of statements are: • After a GET LIST statement has been processed, a file is positioned to the 78K - 83K 3400 characters next non-blank character or, if this is Over 83K 3960 characters a comma, to the character following the comma. A GET EDIT statement following a The DECLARE statement is an exception in GET LIST on the same file must take into that it can be regarded as a sequence of account the position of the file. separate statements, each of which starts wherever a comma occurs that is • If the variable on the left-hand side of not contained within parentheses. For an item of data-directed input is based example: or controlled, and is not currently allocated, the ERROR condition is DCL 1 A raised. The NAME condition is raised 2 B(10,10) INIT(1,2,3, ••• ), for all other errors (including out of 2 C(10,100) INIT«1000) 0), range subscripts) detected on the left­ 2 (D,E) CHAR(20) VAR, ••• hand side of data-directed input items.

In this example, each line can be • The following sequence: treated by the compiler as a separate DECLARE statement in order to DCL SYSPRINT FILE; accommodate it in the work area. The compiler will also treat in the same way the INITIAL attribute when it is followed by a list of items separated by OPEN FILE(SYSPRINT)i commas that are not contained within parentheses. Each item may contain will cause the UNDEFINEDFILE condition initial values that, when expanded, do to be raised. Omission of either or not exceed the maximum length. The both statements will result in correct above also applies to the use of the execution. The file should be declared INITIAL attribute in a DEFAULT implicitly or with the attributes STREAM statement. and OUTPUT.

The (F) compiler can use up to 90K bytes for its work area. It is possible that programs with large DECLARE statements will not compile successfully on the optimizing compiler although they had compiled successfully on the (F) compiler. The following techniques are suggested to • The (F) compiler initializes a varying­ overcome this problem: length string to a null string, the equivalent of: 1. Increase the main storage available to the compiler, unless the space STR ..., available already gives the largest statement length. whenever such a string is allocated. The optimizing Compiler does not perform any 2. Simplify the DECLARE statement so that initialization of varying-length the compiler can treat the statement strings, unless the INITIAL attribute is in the manner described above. used.

34 Appendix C: Bibliography

The following publications describe. in Companion volume to OS PL/I Optimizing and more detail. the facilities of the OS PL/I Checkout Compilers: Language RE~ference optimizing Compiler. the resident library. Manual (Order No. SC33-0009), and TSO: OS and the transient library. PL/I optimizing Compiler: User' f~ Guide - (Order No. SC33-0029). The thrE~e manuals The availability of a publication is form a guide to the writing and execution indicated by its use key. the first letter of PL/I programs using the Optimizing in the order number. The use keys are: Compiler and the associated resident and transient libraries in the batch and time­ G General: available to users of IBM sharing environments of the IBM Operating systems, products, and services System. without charge, in quantities to meet their normal requirements. can also be The programmer's guide is concel:ned with purchased by anyone through IBM branch the relationships between a PL/I program, offices. the optimizing Compiler, and thE~ operating system. It explains how to compile, link­ S Sell: can be purchased by anyone edit, and execute a PL/I program in a batch through IBM branch offices. environment, and it introduces ";job control language, the linkage editor, d~ta L Licensed: property of IBM; management, and other operating system available only to licensees of the features that may be required by a PL/I related program products under the programmer. terms of the license agreement.

OS PL/I Optimizing Compiler: OS PL/I Checkout and optimizing Compilers: Messages Language Reference Manual Order No. SC33-0027 Order No. SC33-0009 Lists all the messages that may be issued The primary source of information on the by the OS PL/I Optimizing Compiler and the language implemented by the OS PL/I associated transient library during Optimizing and Checkout Compilers. It is a processing of a PL/I program. Both the reference manual rather than a tutorial long and short forms of each message are text, and the reader is assumed to have listed where applicable. some previous knowledge of PL/I. The messages are in three groups: The manual contains information on how to write a PL/I source program. For • compile-time messages (generalted by the information on how to compile,- link-edit. compiler during compilation of a PL/I and execute the program, reference should source program). be made to the appropriate programmer's guide. • Execution-time messages (gene-rated by the transient library during execution of the compiled program).

OS PL/I Checkout and Optimizing compilers: • Prompter messages (generated by the Keyword and Terminal Commands Reference compiler when it is used in a time­ Card sharing environment). Order No. SX33-6002 Where appropriate. explanations of the contains a full list of the PL/I Keywords messages and suggested programme'r responses implemented by the OS PL/I optimizing are included. compiler. The keywords are arranged in alphabetical order and each has a brief description of its use. OS PL/I Optimizing Compiler: Execution Logic Order No. SC33-0025 OS PL/I Optimizing Compiler: Programmer's Guide Describes the object module produced by the Order No. SC33-0006 OS Optimizing compiler. and explains how

Appendix C: Bibliography 35 the compiled code uses subroutines from the The OS PL/I Transient Library consists of associated resident and transient standard subroutines that are loaded during libraries. execution of programs compiled by the Os PL/I Optimizing compiler, or the OS PL/I Checkout Compiler. These subroutines are used in error handling, program management, The topics covered include program and input/output, and to provide storage initialization, storage management, dumps. input/output, error handling, and interlanguage communication. The use of This publication is intended primarily for storage dumps for debugging is also use by programmers concerned with the explained. maintenance of the transient library. It summarizes, under functional headings, the The manual is intended primarily for internal logic of the library subroutines, programmers concerned with maintenance of and gives brief details of the the compiler and its libraries. It will relationships between them. also be useful for applications programmers who require an understanding of th1e processes of execution. OS PL/I optimizing Compiler: Installation Order No. SC33-0026 OS PL/I Optimizing Compiler: Proqram Logic Intended primarily for programmers Order No. LY33-6007 responsible for installing the OS PL/I Optimizing Compiler and the associated The internal design of the OS PL/I resident and transient libraries. It is Optimizing Compiler is described in this divided into four parts that give detailed manual; which is written for use by information on installation procedures and programmers responsible for maintenance of storage estimates. the compiler. The manual is intended primarily as a guide to analysis of the program listings by people who are generally familiar with the compiler. TSO: However, overall and component descriptions OS-PL/I Optimizing compiler: User's Guide are provided for use by readers who have no Order No. SC33-0029 prior knowledge of the compiler design. This manual is a companion volume to os PL/I Checkout and Optimizing Compilers: Language Reference Manual (Order No. SC33- OS PL/I Resident Library: 0009) and OS PL/I Optimizing Compiler: Proqram Logic Programmer's Guide (Order No. SC33-0006). Order No. LY33-6008 The three manuals form a guide to the writing and execution of PL/I programs The OS PL/I Resident Library consists of using the Optimizing Compiler and the standard subroutines that are linke-edited associated resident and transient libraries with object programs generated by the OS in the batch and time-sharing environments PL/I Optimizing Compiler. The library is of the IBM Operating System. used in program management, input/output, conversion; and inter language The manual comprises two parts: communication, and also includes many computational subroutines. • Guide: An explanation of how to use the compiler in a time-sharing (TSO) This publication is intended primarily for environment, and a description of the use by programmers concerned with the conversational I/O feature of the maintenance of the resident library. It compiler. summarizes; under functional headings, the internal logic of the libary subroutines, • Command Language: A description of the and gives brief details of the PLI command and its operands. relationships between them. The two parts are designed so that it can be used independently or its two parts included in the TSO publications Terminal OS PL/I Transient Library User's Guide (Order No. GC28-6763) and Program Logic Command Language Reference (Order No. GC28- Order No. LY33-6009 6732), respectively.

36 Order No. GC33-0001-2, Page Revised by TNL GN33-6085, April 1973

Appendix D: Planning Information for eMS

The OS PL/I Optimizing Compiler and its • Teleprocessi.ng. The TCAM data manage­ libraries can be used with the Conversa­ ment facility and the TRANSIENT file tional Monitor System (CMS) of the Virtual attribute are included in this Machine Facility/370 (VM/370). restriction. The optimizing compiler supports those • INDEXED and VSAM files. I/O d~vices that it supports under the operating system, provided that these • The PL/I sort facility. devices are supported by VM/370. A list of the devices supported under VM/370 is • The PL/I checkpoint/restart facility. given in the VM/370 Planning and System Generation Guide. • ASCII data sets. A minimum of 320K bytes of virtual • The BACKWARDS attribute for magnetic storage is required for the CMS virtual tape files. machine for execution of the optimizing compiler under CMS. • Spanned (VS-format or VBS-format) records" (BDAM) • All PL/I source programs that can be compiled by the optimizing compiler under • PL/I FETCH and RELEASE statements. the IBM Operating System will be accepted and compiled by the optimizing compiler These restrictions are execution-time under CMS. restrictions under CMS; they do not i~pplY' to programs compiled under CMS and ex­ However, object programs produced by ecuted under the IBM Operating System. the optimizing compiler to be executed under CMS cannot use the following facil­ For the availability of the optimizing ities: compiler under CMS refer to IBM Program Product Design Objectives, • Multitasking Order No. GC33-0036.

Appendix D: Planning Information for CMS 37

Index

"INCLUDE character sets 4 avoiding use of preprocessor 5 CHECK condition "PAGE statement 16 language extension 15 "SKIP statement 16 checkpoint/restart facilities required 23 checkpoint/restart facility 32 CMS (Conversational Monitor system) 37 abbreviations for keywords 25 optimizing compiler restrictions 37 access methods required 23 COBOL option 20 ACOS built-in functions 20 commerical programs ADDR built-in function effect of optimization 3 argument, valid 31 common constant aggregate elimination of 11 string overlay defining 18 common control data aggregates 13 elimination of 11 ALLOCATION built-in function common expression returned value 31 definition 7 area variable elimination of 7 length field 31 comparison array data types allowed 20 addressing optimization by compatibility defactorization 9 between OS and DOS versions of addressing optimization by expression compiler 5 simplification 9 between releases 5 assignment optimized 11 library subroutines 5 dimensions, maximum number of 31 with PL/I (F) Compiler 31 in same expression as structure 18 compilation initialization optimized 9 input/output devices required 21 replacement of constant expressions 9 machine requirements 21 array/structure operations speed 3 ASCII data sets 17 compiler 3,37 ASCII option of ENVIRONMENT attribute 17 optimization 3 ASIN built-in function 20 options 4 assignment restrictions under CMS 37 array and structure, optimized 11 specifying card-image format output 5 attributes, default use with CMS 37 DEFAULT statement 15 compiler option, deleted auxiliary storage temporary reinstatement 4 requirement for compiler and condition-handling 4 libraries 21 CONNECTED attribute 18 constant exponents replacement of 9 based variable constant expressions defined variable replacement of 9 subscripted or based locator 16 constant multipliers VARYING attribute 18 replacement of 9 bibliography 35 contiguous storage block size CONNECTED attribute 18 in ENVIRONMENT attribute 16 control programs branch instructions MFT 22 base register allocation optimized 11 MVT 22 BUFOFF option of ENVIRONMENT attribute 17 VS1 22 built-in function VS2 22 in-line code 10 control programs required 22 built-in functions 31 control variable of DO statement BUILTIN attribute 31 restriction 33 Conversational Monitor System (CMS) 37

Index 39 conversions ENDFILE condition 34 in-line code 10 data- and list-directed input 34 ENTRY attribute nesting in descriptor list 32 data entry constant 19 aggregates 13 entry expression types 13 GENERIC attribute 19 data aggregates 18 entry name data list as argument 31 matching with format list at compile external, explicit declaration 32 time 10 GENERIC attribute 19 dat:a management facilities required 23 internal, declaration 32 data-directed input entry variable 19 ENDFILE condition 34 ENVIRONMENT attribute 16 NAME condition 34 use of variables to specify values 17 unallocated variable 34 error correction data-set organization incompatibility with PL/I (F) for teleprocessing 17 compiler 32 DATE built-in function execution machine requirement 21 machine requirements 21 debugging aids restrictions under CMS 37 condition-handling 4 speed 3 diagnostics 3 expression flow trace 4 transfer out of loop 8 on-units 4 extended precision floating point 19 DECLARE statement extensions to language 15 label on 33 extent maximum length 34 in RETURNS attribute/option 32 defactorization 9 external procedure default attributes dynamiC loading from auxiliary DEFAULT statement 15 storage 16 DEFAULT statement 15 effect of label 15 DEFINED variable FETCH statement 16 record I/O 17 file constant 18 DEI.AY statement file variable 18 machine requirement 21 file-name expressions 18 depth of structure, maximum 31 floating-point data diagnostics 3 default precision 19 length of messages 4 extended precision 19 severity level 4 flow trace 4 specifying inclusion of line numbers 5 format list specifying inclusion of statement matching with data list at compile numbers 5 time 10 dimensions, maximum number of 31 FORTRAN option 20 DISPLAY statement function 19 length of reply 31 effect of entry argument 31 division operations optimization by repeated subtraction 8 DO statement GENERIC attribute 19 control variable restriction 33 generic selection 19 special case code 10 documentation 35 dummy entry variable 31 IF statement dump branching optimized 12 DD statement for 31 improving efficiency by compound dump facility 32 expression 8 dump, specifying 4 implementation restrictions 31 dynamic loading of procedures 16 in-line code for built-in function 10 for record I/O 10 edit-directed transmission for string manipulation 10 matching of format lists with data in-line code for conversions 10 lists optimized 10 incompatibilities with (F) compiler 31 elimination of common constants 11 INDEX built-in function elimination of common control data 11 within preprocessor statement 16 INITIAL attribute expressions in 19

40 INITIAL attribute (CONTINUED) loop (CONTINUED) maximum length 34 transfer of expressions 8 initialization by expression or undesired effect of optimization 8 function 19 use of registers for frequently- initialization of arrays and structures modified values 11 optimized 9 initialization of varying-length strings 34 machine requirements input/output 14 auxiliary storage 21 use of file-name expressions in for compilation 21 statements 18 for execution 21 input/output devices input/output devices 21 required for compilation and link- magnetic tape positioning (REREAD editing 21 option) 33 INTER option 20 margin indicator 4 interlanguage communication 5,20 margins, source statement 4 internal procedure 32 matching of format lists with data lists interrupt, imprecise optimized 10 specifying processing code generation 4 mathematical built-in functions 20 iSUB variable maximum length of DECLARE statement 34 beyond subscript range 15 maximum length of INITIAL specification 34 maximum length of statements 33 maximum number of statements 33 key handling for REGIONAL data sets 10 maximum precision keywords and abbreviations, list 25 extended precision floating point 19 message length 4 MFT control program 22 label modification of loop control variables 9 on DECLARE statement 33 moving expressions out of loops 8 on DEFAULT statement 15 undesired effect 8 language extensions 15 multiplication operations language features implemented 13 optimization by repeated addition 8 LENGTH built-in function multiprocessing (M65MP) 23 within preprocessor statement 16 multiprogramming with a fixed number of library subroutines tasks (MFT) 22 compatibility 5 multiprogramming with a variable number of logically grouped for efficiency 11 tasks (MVT) 22 LIKE attribute MVT control program 22 limitation within structure 32 M65MP option 23 limitations, implementation 31 lines per page of compiler output 4 link-editing nesting level input/output devices required 21 printed on source listing 4 restriction, PL/I (F) modules 32 NOMAP option 20 list NOMAPIN option 20 of declaration numbers 4 NOMA POUT option 20 of external symbol dictionary 4 NORESCAN option 15 of implementation dependent NULLO built-in function information 4 incompatibility with PL/I (F) of options used by compiler 4 Compiler 31 of references to identifiers 4 of source input to preprocessor 4 of source program 4 object module of statement numbers with offsets 5 NAME statement 4 of static storage organization 5 production 4 of stora~e requirements for object offset var iable module 5 subscripted or based 16 list-directed input on-units 4 ENDFILE condition 34 operating system facilities file positioning 34 entry-point names 32 listing control statements 16 operating system options loading procedures dynamically 16 M65MP 23 locator variable TSO 22 subscripted or based 16 operating system requirements 22 loop control programs 22 modification of control variable 9 checkpoint/restart facilities 23 recognition for optimization purposes 8 data management facilities 23 special-case code 10

Index 41 operating system requirements (CONTINUED) REFER option sort facilities 23 removal of restrictions imposed by PL/I optimization 3,7 (F) 16 effect on commercial programs 3 REGIONAL data sets 10 effect on scientific programs 3 key handling optimized 10 specifying for given compilation 5 register usage for loops 11 options, compiler 4 RELEASE statement 16 ORDER option REORDER option effect on optimization of register effect on register allocation 11 allocation 11 for 8 inhibits loop optimization 8 replacement of constant multipliers and overlay defining exponents 9 of aggregates 18 requirements machine 21 operating system 22 parameter space 3 record I/O 17 system 21 picture data REREAD option sterling character disallowed 33 compared with REWIND 33 PL/I keywords and abbreviations 25 REREAD option of ENVIRONMENT attribute 17 PL/I language implemented 13 RESCAN option 15 planning information 37 resident library 37 CMS (Conversational Monitor System) 37 auxiliary storage requirement 21 PLIDUMP built-in subroutine use with CMS 37 flow trace 4 restrictions PLIDUMP ddname 31 implementation 31 PL1.DUMP ddname 31 return code generation 32 pointer variable RETURNS attribute/option subscripted or based ~6 extent in 32 preprocessing facilities 15 REWIND option (PL/I (F) Compiler) use of LENGTH and INDEX built-in compared with REREAD 33 functions 16 preprocessor ENTRY attribute 33 SCALARVARYING option of ENVIRONMENT replacement values 33 attribute 17 RETURNS attribute 33 scientific programs specifying card-image format output 4 effect of optimization 3 specifying use of 4 self-defining structures preprocessor scan removal of restriction imposed by PL/I programmer control 15 (F) 16 procedure Simplification of expressions 8 dynamic loading from auxiliary SNAP option storage 16 flow trace 4 internal 32 specifying limits 5 PROD built-in function sort facilities required 23 arguments 31 sort facility 32 returned value 31 SORT/MERGE program program branch code 11 varying-length strings 33 program management 13 source program publications 35 character sets 4 control of listing format 16 margins 4 record format space requirements 3 in ENVIRONMENT attribute 16 special-case code for DO statements 10 record format specification speed effect of omission 33 of compilation 3 Record I/O 17 of execution 3 in-line code 10 statement incompatibilities with (F) compiler 33 execution count 5 parameters and DEFINED variables 17 statement number record size specifying method of derivation 4 in ENVIRONMENT attribute 16 statements redundant expression maximum lengths 33 definition 8 maximum number 33 elimination of 8 sterling picture data, disallowed 33 redundant expression elimination storage possible incompatibility 33 specifying amount available for compilation 4

42 storage control 16 System/370 facilities 23 stream I/O SYSUT1 data set incompatibilities with PL/I (F) uses 21 compiler 34 string .. 32 aggregate argument, restr1ct1on tape positioning (REREAD option) 33 truncation, detection 18 teleprocessing data sets string handling specifying data-set organization in in-line code 10 ENVIRONMENT attribute 17 STRINGSIZE condition 18 terminal structure specifying selected compiler output assignment optimized 11 to 4 in same expression as array 18 Time Sharing Option (TSO) 22 initialization optimized 9 transient library LIKE attribute limitation 32 auxiliary storage requirement 21 maximum depth 31 use with CMS 37 self-defining 16 TSO 22 structure and array assignments types of optimization 7 optimized 11 subroutine 19 subscript UNDEFINEDFILE condition 33,34 common expressions 7 with SYSPRINT SUBSCRIPTRANGE condition UNSPEC pseudovariable with iSUB variables 15 varying string 33 SUBSTR built-in function returned value 31 SUM built-in function VARYING attribute arguments 31 with BASED or DEFINED 18 returned value 31 varying string syntax checking UNSPEC value 33 control of progress into 4 varying-length string SYSPRINT 34 initialization 34 declaration 34 locate-mode I/O 1.7 UND.EFINEDFILE raised 34 virtual storage (VS1) 22 system requirements 21 virtual storage (VS2) 22 for compilation 21 VSl control program 22 for execution 21 VS2 control program 22 System/370 facilities 23

Index 43 Jn~~ / Technical Newsletter This Newsletter No. GN33-6095 Date June 1973

Base Publication No. GC33-0001-2 File No. S360/S370-29

Previous Newsletters GN33-6085

OS PLjI Optimizing Compiler: General Information

© IBM Corp. 1970, 1971, 1972

This Technical Newsletter, a part of version 1, release 2, modification 0 of the IBM Operating System PLjI Optimizing Compiler, Program Product 5734-PL1, provides replacement pages for the subject publication. These replacement pages remain in effect unless specifically altered. Pages to be inserted and/or removed are:

Title page, ii 21,22 1,2 23, 24 3,4 27, 28 5,6 29,30 19,20 33,34

A change to the text is indicated by a vertical line to the left of the change. Summary of Amendments The attached pages contain minor additions or changes to the announcement information published previously for version 1, release 2, modification 0 of the OS PLjI Optimizing Compiler.

Note: Please file this cover letter at the back of the manual to provide a record of changes.

IBM United Kingdom Laboratories Ltd, Publications Dept, Hursley Park, Winchester, Hants, England.

© IB~ Corp. 1972 Printed in U.S.A. ITrn~ / Technical Newsletter This Newsletter No. GN33-6085 Date April1973

Base Publication No. GC33-0001-2 System S360/S370~29

Previous Newsletters None

OS PL/I Optimizing Compiler: General Information

© IBM Corp. 1970,1971,1972

This Technical Newsletter provides replacement pages for the subject publication. These replacement pages remain in effect unless specifically altered. Pages to be inserted and/or removed are:

Title page, ii 37

A change to the text is indicated by a vertical line to the left of the change.

Summary of Amendments Updated planning information for the use of the PL/I Optimizing Compiler under CMS is included.

Note: Please file this cover letter at the back of the manual to provide a record of changes.

IBM United Kingdom Laboratories Ltd, Publications Dept, Hursley Park, Winchester, Hants, England.

© IBM Corp. 1973 Printed in U.S.A. OS PLjI Optimizing Compiler: READER'S General Information COMMENT Order No. GC33-0001-2 FOAM

Your views about this publication may help improve its usefulness; this form will be sent to the author's department for appropriate action. Using this form to request system assistance or additional pUblications will delay response, however. For more direct handling of such requestS, please contact your IBM representative or the IBM Branch Office serving your locality.

Possible topics for comment are:

Clarity Accuracy Completeness Organization Index Figures Examples Legibility

o !l ~ ." oa: » 0' :l ~I •S" I

What is your occupation? ______

Number of latest Technical Newsletter (if any) concerning this publication: ______Please indicate in the space below if you wish a reply.

Thank you for your cooperation. No postage stamp necessary if mailed in the U.S.A. (Elsewhere, an IBM office or representative will be happy to forward your comments.) GC33·Q001·2

Your comments, please ••.

This manual is part of a library that serves as a reference source for systems analysts, programmers, and operators of IBM systems. Your comments on the other side of this form will be carefully reviewed by the persons responsible for writing and publishing this material. All comments and suggestions become the property of IBM.

•••••.•••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••••.•••••••••••••••••••••••••••••••Fold Fold '1

First Class Permit 40 Armonk New York o en "0 r :::;. Business Reply Mail o "0..... No postage stamp necessary if mailed in the U.S.A. 3' N' 5' to (") o 3 Postage will be paid by: "0 ~ I nternational Business Machines Corporation Department 813(HP) 1133 Westchester Avenue White Plains, New York 10604 :::J o-+I 3 .....D.l o· Fold Fold :::J

ro" z ? enw 0') o enw -...J o r\.> <0

International Bu.lne•• Machine. Corporation Data Proce•• lng DIvI.lon 1133 We.tche.ter Avenue, White Plain., New York 10604 jIU.S.A. only)

IIBM World Trade Corporation 1121 United Nation. Plaza, New York, New York 10017 !(Intemlltlonal)