hp.com home products and services support and drivers solutions how to buy
cd-rom home
End of Jump to page title
HP OpenVMS systems
documentation

Jump to content


HP OpenVMS Debugger Manual

HP OpenVMS Debugger Manual


Previous Contents Index

C.12.3 Predefined Symbols

Supported Pascal predefined symbols follow:
Symbol Meaning
TRUE Boolean True
FALSE Boolean False
NIL Nil pointer

C.12.4 Built-In Functions

Supported Pascal built-in functions follow:
Symbol Meaning
SUCC Logical successor
PRED Logical predecessor

C.12.5 Data Types

Supported Pascal data types follow:
Pascal Data Type Operating System Data Type Name
INTEGER Longword Integer (L)
INTEGER Word Integer (W,WU)
INTEGER Byte Integer (B,BU)
UNSIGNED Longword Unsigned (LU)
UNSIGNED Word Unsigned (WU)
UNSIGNED Byte Unsigned (BU)
SINGLE, REAL F_Floating (F)
REAL (Alpha and I64 specific) IEEE S_Floating (FS)
DOUBLE D_Floating (D)
DOUBLE G_Floating (G)
DOUBLE (Alpha and I64 specific) IEEE T_Floating (FT)
QUADRUPLE (VAX and I64 specific) H_Floating (H)
BOOLEAN (None)
CHAR ASCII Text (T)
VARYING OF CHAR Varying Text (VT)
SET (None)
FILE (None)
Enumerations (None)
Subranges (None)
Typed Pointers (None)
Arrays (None)
Records (None)
Variant records (None)

The debugger accepts Pascal set constants such as [1,2,5,8..10] or [RED, BLUE] in Pascal language expressions.

Floating-point numbers of type REAL may be represented by F_Floating or IEEE S_Floating, depending on compiler switches or source code attributes.

Floating-point numbers of type DOUBLE may be represented by D_Floating, G_Floating, or IEEE T_Floating, depending on compiler switches or source code attributes.

C.12.6 Additional Information

In general, you can examine, evaluate, and deposit into variables, record fields, and array components. An exception to this occurs under the following circumstances: if a variable is not referenced in a program, the Pascal compiler might not allocate the variable. If the variable is not allocated and you try to examine it or deposit into it, you will receive an error message.

When you deposit data into a variable, the debugger truncates the high-order bits if the value being deposited is larger than the variable; the debugger fills the high-order bits with zeros if the value being deposited is smaller than the variable. If the deposit violates the rules of assignment compatibility, the debugger displays an informational message.

You can examine and deposit into automatic variables (within any active block); however, because automatic variables are allocated in stack storage and are contained in registers, their values are considered undefined until the variables are initialized or assigned a value.

C.12.7 Restrictions

Restrictions in debugger support for Pascal are as follows.

You can examine a VARYING OF CHAR string, but you cannot examine the .LENGTH or .BODY fields using the normal language syntax. For example, if VARS is the name of a string variable, the following commands are not supported:


DBG> EXAMINE VARS.LENGTH
DBG> EXAMINE VARS.BODY

To examine these fields, use the techniques illustrated in the following examples.
Use Instead of
EXAMINE/WORD VARS EXAMINE VARS.LENGTH
EXAMINE/ASCII VARS+2 EXAMINE VARS.BODY

C.13 PL/I (VAX and Alpha Only)

The following subtopics describe debugger support for PL/I.

C.13.1 Operators in Language Expressions

Supported PL/I operators in language expressions include:
Kind Symbol Function
Prefix + Unary plus
Prefix - Unary minus (negation)
Infix + Addition
Infix - Subtraction
Infix * Multiplication
Infix / Division
Infix ** Exponentiation
Infix || Concatenation
Infix = Equal to
Infix ^= Not equal to
Infix > Greater than
Infix >= Greater than or equal to
Infix ^< Greater than or equal to
Infix < Less than
Infix <= Less than or equal to
Infix ^> Less than or equal to
Prefix ^ Bit-wise NOT
Infix & Bit-wise AND
Infix | Bit-wise OR

C.13.2 Constructs in Language and Address Expressions

Supported constructs in language and address expressions for PL/I follow:
Symbol Construct
( ) Subscripting
. (period) Structure component selection
-> Pointer dereferencing

C.13.3 Data Types

Supported PL/I data types follow:
PL/I Data Type Operating System Data Type Name
FIXED BINARY Byte- (B), Word- (W), or Longword- (L) Integer
FIXED DECIMAL Packed Decimal (P)
FLOAT BIN/DEC F_Floating (F)
FLOAT BIN/ DEC D_Floating (D)
FLOAT BIN/DEC G_Floating (G)
FLOAT BIN/DEC (VAX specific) H_Floating (H)
BIT Bit (V)
BIT Bit Unaligned (VU)
CHARACTER ASCII Text (T)
CHARACTER VARYING Varying Text (VT)
FILE (None)
Labels (None)
Pointers (None)
Arrays (None)
Structures (None)

C.13.4 Static and Nonstatic Variables

Variables of the following storage classes are allocated statically:

STATIC
EXTERNAL
GLOBALDEF
GLOBALREF

Variables of the following storage classes are allocated nonstatically (on the stack or in registers):

AUTOMATIC
BASED
CONTROLLED
DEFINED
PARAMETER

C.13.5 Examining and Manipulating Data

The following subtopics give examples of the EXAMINE command with PL/I data types. They also highlight aspects of debugger support that are specific to PL/I.

C.13.5.1 EXAMINE Command Examples

The following examples show use of the EXAMINE command with a few selected PL/I data types.

C.13.5.2 Notes on Debugger Support

Note the following points about debugger support for PL/I.

You cannot use the DEPOSIT command with entry or label variables or formats, or with entire arrays or structures. You cannot use the EXAMINE command with entry or label variables or formats; instead, use the EVALUATE/ADDRESS command.

You cannot use the EXAMINE command to determine the values or attributes of global literals (such as GLOBALDEF VALUE literals) because they are static expressions. Instead, use the EVALUATE command.

You cannot use the EXAMINE, EVALUATE, and DEPOSIT commands with compile-time variables and procedures. However, you can use EVALUATE and DEPOSIT (but not EXAMINE) with a compile-time constant, as long as the constant is the source and not the destination.

Note that an uninitialized automatic variable does not have valid contents until after a value has been assigned to it. If you examine it before that point, the value displayed is unpredictable.

You can deposit a value into a pointer variable either by depositing another pointer's value into it, thus making symbolic reference to both pointers, or by depositing a virtual address into it. (You can find out the virtual address of a variable by using the EVALUATE/ADDRESS command, and then deposit that address into the pointer.) When you examine a pointer, the debugger displays its value in the form of the virtual address of the variable that the pointer points to.

The debugger treats all numeric constants of the form n or n.n in PL/I language expressions as packed decimal constants, not integer or floating-point constants, in order to conform to PL/I language rules. The internal representation of 10 is therefore 0C01 hexadecimal, not 0A hexadecimal.

You can enter floating-point constants using the syntax nEn or n.nEn.

There is no PL/I syntax for entering constants whose internal representation is Longword Integer. This limitation is not normally significant when debugging, since the debugger supports the PL/I type conversion rules. However, it is possible to enter integer constants by using the debugger's %HEX, %OCT, and %BIN operators, because nondecimal radix constants are assumed to be FIXED BINARY. For example, the EVALUATE/HEXADECIMAL 53 + %HEX 0 command displays 00000035.

C.14 RPG II (VAX Only)

The follow subtopics describe debugger support for RPG II.

C.14.1 Operators in Language Expressions

The following operators are supported in language expressions when the language is set to RPG II:
Kind Symbol Function
Prefix + Unary plus
Prefix - Unary minus (negation)
Infix + Addition
Infix - Subtraction
Infix * Multiplication
Infix / Division
Infix = Equal to
Infix NOT = Not equal to
Infix > Greater than
Infix NOT < Greater than or equal to
Infix < Less than
Infix NOT > Less than or equal to
Prefix NOT Logical NOT
Infix AND Logical AND
Infix OR Logical OR

C.14.2 Constructs in Language and Address Expressions

Supported constructs in language and address expressions for RPG II follow:
Symbol Construct
( ) Subscripting

C.14.3 Data Types

Supported RPG II data types follow:
RPG II Data Type Operating System Data Type Name
Longword binary numeric Longword Integer (L)
Word binary numeric Word Integer (W)
Packed decimal Packed Decimal (P)
Character ASCII Text (T)
Overpunched decimal Right Overpunched Sign (NRO)
Arrays (None)
Tables (None)

C.14.4 Setting Breakpoints or Tracepoints

With RPG II programs, you can set breakpoints using source line numbers, logic cycle labels, user-defined tag names, and subroutine labels. Debugging RPG II programs is somewhat different from debugging programs in other languages, and the additional topics explain where and how you can set breakpoints or tracepoints.

C.14.4.1 Specifications

The following paragraphs describe where you can set breakpoints (or tracepoints) in specifications, using line numbers.

The RPG II program cycle determines the order in which program lines are processed. When setting breakpoints or tracepoints, you can reference the line numbers that RPG II assigns to your program and appear in a listing file or in a debugger source display. The line numbers you specify in columns 1 through 5 of a specification are not used.

The compiler assigns line numbers only to certain specifications at specific points in the logic cycle; therefore, you can specify a breakpoint or tracepoint at these points in the program:

C.14.4.2 Labels

You can specify an RPG II label as a breakpoint or a tracepoint. The following RPG II labels, which correspond to specific points in the logic cycle, are provided in addition to user-defined tags. Note that these labels do not appear in the source code but are accessible from the debugger. The labels do appear in the machine code listing.
RPG II Label Description and Breakpoint Behavior
*DETL Breaks just before outputting heading and detail lines
*GETIN Breaks just before reading the next record from the primary or secondary file
*TOTC Breaks just before performing total-time calculations
*TOTL Breaks just before performing total-time output
*OFL Breaks just before performing overflow output
*DETC Breaks just before performing detail-time calculations

For example:


DBG> SET BREAK *TOTL


Previous Next Contents Index