HP BASIC for OpenVMS I64 Systems V1.6 Release Notes Summary of I64 BASIC V1.6 January 2005 © 2004 Hewlett-Packard Development Company, L.P. Confidential computer software. Valid license from HP required for possession, use or copying. Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documen- tation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license. HP shall not be liable for technical or editorial errors or omissions contained herein. The information is provided "as is" without warranty of any kind and is subject to change without notice. The warranties for HP products are set forth in the express limited warranty statements accompanying such products. Nothing herein should be construed as constituting an additional warranty. Hewlett-Packard Company Palo Alto, California i CONTENTS 1 Release Summary...................................... 1 2 General Notes........................................ 1 3 Feature enhancements................................. 2 4 Problems In Alpha BASIC fixed for V1.6............... 2 5 Known Problems and Restrictions in I64 BASIC V1.6.... 3 5.1 General Problems.................................. 3 5.2 OpenVMS Debugger Problems......................... 5 6 HP BASIC for OpenVMS I64 Systems Documentation and Online Information................................... 6 6.1 Online Release Notes and Help File................ 6 6.1.1 HP BASIC for OpenVMS I64 Systems Online Release Notes.......................................... 6 6.1.2 I64 BASIC DCL Help............................. 6 6.1.3 I64 BASIC Language Topics Help................. 7 6.2 Corrections to Documentation...................... 7 6.2.1 Reference Manual............................... 7 6.2.2 User's Guide................................... 7 7 Reporting problems with I64 BASIC V1.6............... 7 iii Release Notes for I64 BASIC V1.6 1 Release Summary HP BASIC for OpenVMS I64 Systems is a native compiler that runs on and generates code to run on OpenVMS I64 systems. Version V1.6 is a port of the Alpha BASIC compiler to the Itanium archi- tecture. 2 General Notes o Throughout these notes, the term HP BASIC or the name BASIC used alone, applies to HP BASIC for OpenVMS I64 Systems, HP BASIC for OpenVMS Alpha Systems, and HP BASIC for OpenVMS VAX Systems. The following terms refer to information that applies specifically to the corresponding product. I64 BASIC HP BASIC for OpenVMS I64 Systems Alpha BASIC HP BASIC for OpenVMS Alpha Systems VAX BASIC HP BASIC for OpenVMS VAX Systems o I64 BASIC V1.6 minimally requires OpenVMS I64 Version 8.2 to run. o The default data type for I64 BASIC is IEEE S_floating point whereas for Alpha BASIC and VAX BASIC the default is VAX F_ floating point. To continue use of the VAX floating point data types you must use the /REAL_SIZE={SINGLE | DOUBLE | GFLOAT} qualifier, or the OPTION SIZE=REAL {SINGLE | DOUBLE | GFLOAT} statement. Since the VAX floating point data types are not available in the Itanium hardware, they are supported by converting the values to an appropriate IEEE data type, performing the calculation, and then converting the values back to VAX floating point data type. This process can cause rounding errors and the results to differ slightly from those obtained using VAX floating point directly. Note that constants in programs are represented in the de- fault floating point data type unless explicitly specified otherwise, and they may be subject to conversion to IEEE data types. See the white paper, "OpenVMS floating-point arithmetic on the Intel[R] Itanium[R] architecture" at http://www.hp.com/products1/evolution/alpha_retaintrust/download/i64-floating-pt-wp.pdf for more information. 1 Release Notes for I64 BASIC V1.6 o By default, programs are compiled at optimization level 4 (/OPT=LEVEL=4), the highest level of optimization. If you encounter problems with the generated code, try compiling the program with a lower level of optimization. This may correct the problem. Please report any problems to HP, even if the program works correctly at a lower optimization level. 3 Feature enhancements Some minor feature enhancements have been made for version 1.6. These include: o Support for IEEE floating point and QUAD integer data types has been added to the matrix statements: MAT CON MAT IDN MAT ZER MAT NUL$ MAT (+ - *) MAT TRN MAT INV MAT INPUT MAT LINPUT MAT PRINT MAT READ DET o The limit on channel numbers has been raised from 119 to 299 in order to be consistent with a similar change to the OpenVMS RTL routines, LIB$GET_LUN and LIB$FREE_LUN. o The new values ITANIUM and MERCED have been added for the /ARCHITECTURE /OPTIMIZE=TUNE qualifiers. The current Alpha specific values are ignored for I64 systems. 4 Problems In Alpha BASIC fixed for V1.6 A number of problems reported in Alpha BASIC have been fixed in I64 BASIC V1.6. The known problems that have been fixed include: o Certain programs using GOSUB statements caused the opti- mizer to abort in the GEM_IL_DETERMINE_CONFLICT routine. The workaround was to compile with /NOOPTIMIZE. This problem has been fixed. o Compiling very large programs can cause the compiler to abort in the SYM_INSERT_CONSTANT routine. This occurred when a rare set of circumstances caused the compiler's memory manager to become confused. The workaround was to rearrange the program 2 Release Notes for I64 BASIC V1.6 in some trival way such as reordering some declarations. This problem has been fixed. o The ability to declare a QUAD sized key in an OPEN statement was inadvertently omitted. The workaround was to declare a RECORD of two LONG elements and MAP this onto the QUAD size variable, and then to use the RECORD name in the OPEN statement. This problem has been fixed. o The inability to OPEN a relative file with ACCESS APPEND has been a restriction. The workaround was to use an USEROPEN routine. This restriction has been removed. o Compiling a program containing a large number of OPEN state- ments with too large a total number of KEY segments declared caused the compiler to abort in the PROCESS_RECORD_KEY rou- tine. The workaround was to reference fewer KEY segments in a single program module. This problem has been fixed. o The compiler sometimes aborts in the GEM_DA_SUBSCR_VECTORS routine. This was a problem with the optimizer and the workaround was to compile with /NOOPTIMIZE. This problem has been fixed. 5 Known Problems and Restrictions in I64 BASIC V1.6 5.1 General Problems The following are known general problems with I64 BASIC V1.6. o Floating point numbers displayed in E-format may differ. In some cases floating point numbers displayed in E-format may contain an additional zero in the exponent field. For example, 6.0E+002 instead of 6.0E+02 o Floating point exceptions not accurately reported. In some cases a floating point exception may not be accu- rately reported. For example: a divide-by-zero exception may be reported as an invalid-number. o Inability to open UNDEFINED type file for output. It is currently not possible to open a file of type UNDEFINED for output. Workaround: Create an empty file with the desired attributes by some other means, for example with a program in a dif- ferent language or with the DCL command CREATE/FDL. Then in BASIC open the file for input with the APPEND attribute. The following code fragment illustrates the technique. 3 Release Notes for I64 BASIC V1.6 %INCLUDE "$FDLDEF" %FROM %LIBRARY "SYS$LIBRARY:BASIC$STARLET" EXTERNAL INTEGER FUNCTION FDL$CREATE MAP (outbuff) STRING myrec = 512 DECLARE INTEGER i, fdlstat DECLARE STRING resultname fdlstat = FDL$CREATE ("RECORD; FORMAT UNDEFINED;", & "myfilename", ".DAT", resultname,, & FDL$M_FDL_STRING + & FDL$M_DEFAULT_STRING + & FDL$M_FULL_OUTPUT) OPEN resultname FOR INPUT AS FILE #3, ORGANIZATION UNDEFINED, & ACCESS APPEND, & MAP outbuff, & RECORDTYPE ANY myrec = ... PUT #3 o DET incorrect with default XFLOAT type. When the default floating point type is set to XFLOAT, the result of the determinant statement (DET) is incorrect. Workaround: Use explicitly declared variables of XFLOAT type, and avoid using XFLOAT type as the default floating point type when the DET statement is used. o The most negative integer constants cannot be represented. The compiler incorrectly gives an integer overflow message when the most negative integer constants: BYTE -128% WORD -32768% LONG -2147483648% are used. Workaround: Use the appropriate expression:. BYTE -127% - 1% WORD -32767% - 1% LONG -2147483647% - 1% o Passed by value quadword arguments in STARLET are not yet supported. Since routines that declare pass by value quadword parameters are not yet supported by BASIC, declarations of routines that do this are not included in BASIC$STARLET.TLB. Workaround: Use of the these routines should be avoided until full support of 64-bit quantities is provided. 4 Release Notes for I64 BASIC V1.6 o The CMA facility found in BASIC$STARLET.TLB is incompatible with BASIC. BASIC is not currently thread safe and will not work with the CMA$DEF module in BASIC$STARLET.TLB. Compiling it with BASIC results in a number of Record type undefined errors. Workaround: BASIC does not support the CMA facility and compiling the CMA$DEF module should be avoided. 5.2 OpenVMS Debugger Problems With this release of the compiler, debugging support for I64 BASIC programs is not complete. The "OpenVMS I64 V8.2 Release Notes" document contains general release notes on the debugger. This section describes additional problems and workarounds specific to I64 BASIC programs. o Examining a symbol declared with the DIMENSION keyword some- times causes a debugger access violation. Workaround: Type SHOW SYMBOL/ADDRESS then examine the memory location directly. o Examining a field in a record sometimes fails with the error: %DEBUG-W-NOFIELD, 'xxx' is not a field in this record Workaround: Examine the entire record. o In some cases the Debugger can not determine the end of user code. In these cases, the following message may be produced if you STEP at the last line of user application code: DBG> Step %DEBUG-W-SCRNOSRCLIN, no source line for address xxxxxxxx for display in SRC You can ignore this message. o Examining some types of variables is not possible, including: A RECORD variable, or an array of RECORDs which is declared in a MAP DYNAMIC and also passed as a parameter to another routine. o Examining EXTERNAL constants with a plain EVALUATE command results in a warning message. Instead the EVALUATE/ADDRESS command should be used. Note that it is not possible to display EXTERNAL constants in floating point format. o Problems with examining dynamic objects in the debugger. 5 Release Notes for I64 BASIC V1.6 Certain types of dynamic objects referenced by descriptors cannot be displayed in the OpenVMS debugger. Workaround: The inability to display these kinds of objects is a restriction. 6 HP BASIC for OpenVMS I64 Systems Documentation and Online Information 6.1 Online Release Notes and Help File I64 BASIC provides the following online information, which is copied to the user's system during installation: o The HP BASIC for OpenVMS I64 Systems online Release Notes o I64 BASIC DCL Help o I64 BASIC Language Topics Help 6.1.1 HP BASIC for OpenVMS I64 Systems Online Release Notes The HP BASIC for OpenVMS I64 Systems online Release Notes pro- vide a copy of these notes online. After I64 BASIC has been installed, the online Release Notes can be displayed on the screen using the TYPE command: $ TYPE/PAGE SYS$HELP:BASIC01n.RELEASE_NOTES For example, the Release Notes for Version 1.6 are named BA- SIC016.RELEASE_NOTES. To display or print the I64 BASIC Release Notes before in- stalling I64 BASIC, specify OPTIONS N at the end of the @VM- SINSTAL command line (see the I64 BASIC installation guide). 6.1.2 I64 BASIC DCL Help The I64 BASIC DCL HELP module in SYS$HELP:HELPLIB.HLB provides online access to I64 BASIC DCL help. This help describes all the qualifiers of the BASIC compiler. To view the online I64 BASIC DCL help file using the HELP com- mand, type: $ HELP BASIC For example, to display help on the /LINES qualifier type: $ HELP BASIC /LINES You can abbreviate the HELP command words. For instance, to specify help on the /SEPARATE_COMPILATION qualifier, you might use the following command: $ HELP BAS /SEP 6 Release Notes for I64 BASIC V1.6 Alternatively, you can extract the module BASIC from the help library SYS$HELP:HELPLIB.HLB to a separate file. Once extracted to a file, use the SEARCH command or an editor to look up items in the file. To extract the BASIC DCL HELP module from the help library: $ LIBRARY/EXTRACT=BASIC/OUTPUT=BASIC_HELP.TXT SYS$HELP:HELPLIB.HLB 6.1.3 I64 BASIC Language Topics Help HELP on BASIC language topics, available from the VAX BASIC environment is accessible from DCL in I64 BASIC. For help on language features, type the following command at the DCL prompt: $ HELP/LIBRARY=BASICHELP Alternately, a symbol can be defined to access help on BASIC language features directly. For example, the DCL command: $ BASHELP == "HELP /LIBR=BASICHELP" will allow you to type: $ BASHELP BASIC-topic 6.2 Corrections to Documentation The following corrections should be made to the Alpha BASIC manuals. 6.2.1 Reference Manual Corrections to the online HTML documentation HP BASIC for Open- VMS Systems Reference Manual. o The Table of Result Data Types in Alpha BASIC Expressions in Section 1.6.1.2 has two incorrect entries in the online HTML documentation. The table in the paper and PDF documen- tation however is correct. The entries for GFLOAT/SFLOAT and SFLOAT/GFLOAT should be GFLOAT. 6.2.2 User's Guide Corrections to the HP BASIC for OpenVMS Systems User Manual. o The conditional at the end of Example 13-1, in the "File Input and Output" chapter should have an equal sign instead of "AND". It should read as Rms_status = Rms$_normal instead of Rms_status AND Rms$_normal. 7 Reporting problems with I64 BASIC V1.6 If you experence a problem, please file a PTR problem report, including enough information to reproduce the problem. Thank you for your continued support of HP BASIC for OpenVMS I64 Systems. 7