HP OpenVMS Systems Documentation
HP OpenVMS Debugger Manual
Order Number: AA-QSBJE-TE
This manual explains the features of the OpenVMS Debugger for programmers in high-level languages and assembly language.
Revision/Update Information: This manual supersedes the HP OpenVMS Debugger Manual, Version 7.2.
OpenVMS I64 Version 8.2
© Copyright 2005 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 Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license.
The information contained herein is subject to change without notice. The only warranties for HP products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. HP shall not be liable for technical or editorial errors or omissions contained herein.
Intel and Itanium are trademarks or registered trademarks of Intel Corporation or its subsidiaries in the United States and other countries.
Printed in the U.S.A.
The HP OpenVMS documentation set is available on CD-ROM.
This document was prepared using DECdocument, Version 3.3-1b.
This manual is for programmers at all levels of experience. It covers all user interfaces of the OpenVMS Debugger:
The OpenVMS Debugger on OpenVMS Alpha systems can access all the extended memory made available by the 64-bit processing of the OpenVMS Alpha operating system. Hence, you can examine and manipulate data in the complete 64-bit address space.
The OpenVMS Debugger has been internationalized. For Asian users, the debugger's HP DECwindows Motif for OpenVMS, command line, and screen mode user interfaces can be used with multibyte characters.
You can use the debugger to debug code only in user mode. You cannot debug code in supervisor, executive, or kernel modes.
This manual is organized as follows:
The following documents may also be helpful when using the debugger.
This manual emphasizes debugger usage that is common to all or most supported languages. For more information specific to a particular language, see:
For information about the linking of programs or shareable images, see the HP OpenVMS Linker Utility Manual.
For information about debugging code in supervisor, executive, or kernel modes (that is, in other than user mode), see the OpenVMS Delta/XDelta Debugger Manual in the OpenVMS documentation set. This manual contains information about debugging programs that run in privileged processor mode or at an elevated interrupt priority level.
See the OVMS_ALPHA_SYS_ANALYS_TLS_MAN for information on debugging operating system code. This manual describes how to activate the OpenVMS System-Code Debugger through the OpenVMS Debugger, and debug within the OpenVMS System-Code Debugger environment.
For information on the OpenVMS System-Code Debugger-specific commands, see the CONNECT and REBOOT commands in Part 6.
For general information about the HP DECwindows Motif for OpenVMS user interface, see the VMS DECwindows User's Guide.
For additional information about HP OpenVMS products and services, visit the following World Wide Web address:
HP welcomes your comments on this manual. Please send comments to either of the following addresses:
How to Order Additional Documentation
For information about how to order additional documentation, visit the following World Wide Web address:
VMScluster systems are now referred to as OpenVMS Cluster systems. Unless otherwise specified, references to OpenVMS Clusters or clusters in this document are synonymous with VMSclusters.
In this manual, every use of DECwindows and DECwindows Motif refers to HP DECwindows Motif for OpenVMS software.
This manual contains many figures showing the DECwindows Motif user interface to the debugger. Because the display configuration of this interface is customizable, these figures may not exactly picture the appearance of debugger displays on your system.
The examples in this manual have not been updated to reflect the fact that the OpenVMS Debugger on OpenVMS Alpha systems can access all the extended memory made available by the 64-bit processing of the OpenVMS Alpha operating system. You should note that hexadecimal addresses are 16-digit numbers on Alpha and 8-digit numbers on VAX. For example,
The following conventions are also used in this manual:
This part introduces the Debugger.
On Alpha processors, you can use the debugger with programs written in the following Compaq languages:
On I64, you can use the debugger with programs written in the following Compaq languages:
The debugger recognizes the syntax, data types, operators, expressions, scoping rules, and other constructs of a supported language. You can change the debugging context from one language to another (with the SET LANGUAGE command) during a debugging session.
The debugger is a symbolic debugger. You can refer to program locations by the symbols used in your program---the names of variables, routines, labels, and so on. You can also specify explicit memory addresses or machine registers if you choose.
The debugger recognizes the data types generated by the compilers of all supported languages, such as integer, floating-point, enumeration, record, array, and so on, and displays the values of each program variable according to its declared type.
With the debugger, you can enter and display a variety of data forms and data types. The source language of the program determines the default format for the entry and display of data. However, you can select other formats as needed.
Once the program is under control of the debugger, you can start or resume program execution with the GO or STEP command. The GO command causes the program to execute until specified events occur (the PC points to a designated line of code, a variable is modified, an exception is signaled, or the program terminates). You can use the STEP command to execute a specified number instructions or lines of source code, or until the program reaches the next instruction of a specified class.
You can set a breakpoint with the SET BREAK command, to suspend program execution at a specified location in order to check the current status of the program. You can also direct the debugger to suspend execution when the program is about to execute an instruction of a specific class. You can also suspend execution when certain events occur, such as exceptions and tasking (multithread) events.
You can set a tracepoint with the SET TRACE command, to cause the debugger to report each time that program execution reaches a specified location (that is, each time the program counter (PC) references that location). As with the SET BREAK command, you can also trace the occurrence of classes of instructions and monitor the occurrence of certain events, such as exceptions and tasking (multithread) events.
You can set a watchpoint with the SET WATCH command to cause the debugger to suspend program execution whenever a particular variable (or other specified memory location) has been modified, at which point the debugger reports the old and new values of the variable.
You can use the EXAMINE command to determine the value of a variable or memory location. You can use the DEPOSIT command to change that value. You can then continue execution of the program to determine the effect of the change without having to recompile, relink, and rerun the program.
You can use the EVALUATE command to compute the value of a source-language expression or an address expression in the syntax of the language to which the debugger is currently set.
You can use logical control structures (FOR, IF, REPEAT, WHILE) in commands to control the execution of other commands.
You can debug shareable images (images that are not directly executable). The SET IMAGE command enables you to access the symbols declared in a shareable image (that was compiled and linked with the /DEBUG qualifiers).
You can debug multiprocess programs (programs that run in more than one process). The SHOW PROCESS and SET PROCESS commands enable you to display process information and to control the execution of images in individual processes.
You can debug tasking programs (also known as multithread programs). These programs use Compaq POSIX Threads Library or POSIX 1003.1b services, or use language-specific tasking services (for example, Ada tasking programs). The SHOW TASK and SET TASK commands enable you to display task information and to control the execution of individual tasks.
On VAX processors, you can debug vectorized programs, that is, programs that use VAX vector instructions. You can control and monitor execution at the vector instruction level, examine and deposit vector instructions, manipulate the contents of vector registers, use a mask to display specific vector elements, and control synchronization between the scalar and vector processors. For informationon debugging vectorized programs, see the OpenVMS Debugger Manual Version 7.2.