Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Programming Tools Release Notes: For HP-UX 11.x Systems > Chapter 1 New and Changed Features

HP Distributed Debugging Environment (HP DDE)

» 

Technical documentation

» Feedback
Content starts here

 » Table of Contents

The HP Distributed Debugging Environment (HP DDE) is a high-level language debugger for the HP-UX operating system. HP DDE operates on object files generated by the HP C, HP C++, HP aC++, HP FORTRAN 77, HP Fortran 90, and HP Pascal compilers. HP DDE provides a powerful graphical user interface based on the OSF/Motif standard. HP DDE also provides a line-mode user interface.

Although DDE currently ships with HP compilers, DDE will be discontinued in a future compiler release. HP WDB is the primary debugger for software development on HP-UX, and the ultimate replacement for DDE.

Summary of Changes in HP DDE 4.24

HP DDE 4.24 is primarily a maintenance release, however it does include several feature changes.

  • Print command denotes inherited classes or objects.

  • Search command performs only case-sensitive matches.

Print Command Denotes Inherited Classes or Objects

When you print an object or a class, if the class is inherited, DDE denotes the item with Class Type : Inherited Class next to the name.

For example, if myClass is an inherited object from myParent, when you use the command print myClass, DDE prints
Class type : Inherited class

in the output.

Search Command Performs only Case-sensitive Matches

The search command default behavior now performs case-sensitive matches. The DDE search command no longer supports the -ins or -sens options to allow case-insensitive matches.

Search Command Syntax

Search for a given string in the source file display area. If the command has no arguments, the debugger repeats the last search using the same search string and search direction.

FORMAT

search [ -backward | -reverse | -forward ] [ -interactive | search_string ]

ARGUMENTS

backward

Search backward toward the beginning of the file.

reverse

Same as backward.

forward

Search forward toward the end of the file. This is the default.

interactive

Pops up a search dialog box. The defaults for the search string and direction of the search come from the last search — interactive command. You cannot specify a search string as an argument if you use the -interactive option.

search_string

Search for text matching the text string or regular expression pattern search_string, starting from the current cursor location.

Summary of Changes in HP DDE 4.23

HP DDE 4.23 is primarily a maintenance release, however it does include changes to the DDE Menu Bar, and one new option, the -link/nolink command line option.

Changes to the DDE Menu Bar

The Tools menu has been removed from the HP DDE Menu Bar.

-link/nolink command option

The -link/nolink command line option is available for use with the property command to specify whether symbolic links will be used when displaying the source path. This option is available for use in line mode only (there is no way to access this option from the DDE GUI).

The syntax for the option is as follows:

property follow -link

property follow -nolink

The default behavior of DDE in line mode is to follow the link (property follow -link). This displays the true source path instead of the symbolic link.

To show the symbolic link instead of the true source path, use the following command-line option.

property follow -nolink

For example, given a source file named helloworld.cpp with the following symbolic link:

$ ll helloworld.cpp

lrwxrwxr-x 1 1 user1 grp1 21 Apr 15 2000 helloworld.cpp -> subdir/helloworld.cpp

by default, DDE in line mode displays the source path as:

Source File: /tmp/user1/subdir/helloworld.cpp

If property follow -nolink is specified, DDE displays the source path as:

Source File: /tmp/user1/helloworld.cpp

You can show the setting of the follow -link/nolink option with the command list property follow.

The default behavior of DDE in GUI mode has been changed to follow the symbolic links when displaying the source path
(property follow -link). To change this to the previous behavior:

  • Create the .softbench directory in your home directory if none exists.

  • Inside the .softbench directory create a file called wusr.conf if none exists.

  • In the wusr.conf file you can add and update as follows.

    • RESOLVE_SYMLINKS=0

      The DDE GUI will then display the symbolic link instead of the true source path.

You can show the setting of the follow -link/nolink option with the list property follow command.

Summary of Changes in HP DDE 4.22

HP DDE 4.22 is primarily a maintenance release, which includes only one new option.

The -unsetenv command-line option is available for use with the debug and restart commands to unset or clear environment variables.

The syntax for the option is:

debug [-unsetenv env_var [,env_var]...]

restart [-unsetenv env_var [,env_var]...]

For example, use the following command-line option to restart the target program, and to clear the application-specific environment variable SEASON.

restart -unsetenv SEASON

In DDE, to see the current values for environment variables:

  1. Click on Execution on the menu bar.

  2. Select Get Current Program Info.

The dialog box displays information, including environment variables, for the current program.

Summary of Changes in HP DDE 4.21

HP DDE 4.21 is a maintenance release and includes only defect fixes.

Summary of Changes in HP DDE 4.20

HP DDE 4.20 contained the following new features:

  • Support for both 32-bit and 64-bit development environments

  • Support for additional Fortran 90 intrinsics: LBOUND, UBOUND, SIZE, SIZEOF, ASSOCIATED, ALLOCATED, and PRESENT

Summary of Changes in HP DDE 4.10

HP DDE 4.10 contained the following new features:

  • Kernel thread support

  • Hardware watchpoints

  • Changes to the Menu Bar

These features are summarized below. For details, see the debugger online help.

Kernel Thread Support

HP DDE now supports the debugging of threaded applications that are implemented using kernel threads, as well as applications implemented using HP DCE threads.

The kernel threads implementation uses the 1x1 threads model.

In a kernel threads application, multiple threads can execute concurrently on a multi-processor machine. Similarly, multiple threads can be stopped at a given time. Therefore, a kernel threads application is a truly parallel application. Execution is nondeterministic; multiple runs of the program using the same input and initial state can result in different execution order and different output.

In an HP DCE threads implementation, only one thread can execute at any given time, regardless of the number of available processors. Therefore, an HP DCE threads application is not truly parallel.

The debugger assumes that a multi-threaded target program is a kernel threads application unless you specify otherwise. To debug an HP DCE threads application, use the -dce_thread option with either the dde(1) command or the debug command. If you debug an HP DCE threads application without specifying this option, debugging commands may not work as expected.

When you debug a program that uses kernel threads, several threads may be running at the same time. When the debugger stops program execution because of a debugger event that affects one thread, the debugger uses a stop-the-world model: all the threads stop running.

Multi-threaded applications may execute quite differently when they are invoked by the debugger because the debugger takes control of the thread scheduler. Some debugger commands, like step and thread
-select
, override the thread scheduler.

Knowing how debugger commands operate is particularly important for kernel threads applications.

  • Execution Commands

    The go command operates on all enabled threads. In a kernel threads application, this means that the go, go -return, and go -until commands cause all enabled threads to run.

    The step, goto, and call commands operate only on the selected thread. All other threads remain stopped.

    Any execution command (such as step) that you issue when the current thread is different from the selected thread will restore the environment to that of the selected thread. (The debugger behaves the same way when the Current Location is different from the PC Location.)

  • Expression Commands

    Commands that operate on expressions, such as print, dump, and set, operate only on the current thread. Ordinarily the current thread is the same as the selected thread, but you can change the current thread by using the environment command or the Examine button in the Threads dialog box.

    DDE supports thread local storage (TLS). Use the __thread pseudo type qualifier to define TLS variables in the application. At run time, each thread in the application has its own copy of the TLS variables. You can then use the print and set commands to evaluate and change the values of the TLS variables for the current thread.

    If you issue a watchpoint command followed by a go command, the way the debugger behaves depends on whether the watchpoint is a hardware watchpoint or a software watchpoint.

For online help on kernel threads debugging, choose "Common Debugging Tasks: Command Line" in the main help window, then choose "Debugging Multi-Threaded Applications" under "Debugging in Special Situations."

Hardware Watchpoints

HP DDE 4.10 supports hardware watchpoints, which vastly improve the debugger's speed of execution when you use data watchpoints.

With hardware watchpoints, the debugger uses hardware page protection to determine when the value of a variable changes. Hardware watchpoints can be set only on static data; they cannot be set on data stored in registers.

You can obtain hardware watchpoints either with the watchpoint command or through the debugger's graphical user interface.

  • If you use the watchpoint command without specifying any granularity, the debugger attempts to set a hardware watchpoint by default. If it cannot set a hardware watchpoint, it reverts to the previous default of statement granularity.

    If you specify the -hw option with the watchpoint command, the debugger sets a hardware watchpoint if possible. If it cannot set a hardware watchpoint, it issues an error message and does not set a watchpoint.

  • If you choose the Watch: Set at Modification ( ) menu item, the debugger attempts to set a hardware watchpoint, and sets a statement watchpoint if it cannot do so.

    In the Watch: Set... menu item, the default setting is a Stop watchpoint, which is the fastest possible setting since the debugger only checks the value of the variable when it stops for some other reason. Choose Modification to have the debugger set a hardware watchpoint if it can do so.

For online help on hardware watchpoints, choose "HP DDE Command Reference" in the main help window, then choose "Alphabetical List of Commands", then choose watchpoint. Or choose "Graphical User Interface", then choose "Watch Menu."

Changes to the Menu Bar

The HP DDE Menu Bar now contains a Tools pull-down menu with one selection, Performance Analyzer. This menu selection starts the Puma performance analysis tool, allowing you to run Puma on the program you are debugging.

In addition, the File: Quit menu selection has been changed to File: Exit.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© Hewlett-Packard Development Company, L.P.