Debugging with IBM VisualAge C++

You debug your programs in the VisualAge C++ Integrated Development Environment (IDE) in a substantially different way from the traditional edit/compile/link/debug methodology. The VisualAge IDE is designed to make the entire development process easier and more efficient. Debugging tasks are simplified in the following ways:

No Special Debugging Options

When you build your application within the IDE you do not need to specify special compiler or linker options for debugging. Because the IDE maintains a database or "codestore" of information about the functions, classes, variables, statements, and other information in your program, the IDE uses this codestore to access any required debugging information. The executable you debug can be the same executable you ship to customers. Because it does not contain debug information, it is more compact.

Breakpoints Can Be Set Any Time

You can set a breakpoint on any statement, function, virtual function, or class, before you start debugging. You can only set a breakpoint on a statement in functions that you build. As you add new capabilities to your program, you can set breakpoints in your new code so that the next time you debug your program, execution stops in your new code, allowing you to narrow down the scope of debugging.

Breakpoints are stored in your project in relation to your source code, not to executable addresses. If you add code to your program and rebuild it, the context of existing breakpoints is preserved. Each time you start debugging a process, the breakpoints you have set for the project are set at the appropriate addresses in the process. Once a process has started, you can disable or remove breakpoints for that process without affecting those breakpoints in other concurrent or subsequent debugging runs of the program.

Bugs Can Be Corrected from Within the Debug Pages

You can correct a bug in any source view within a debug page, and quickly rebuild your application. This causes all processes for the project that are running under debug control to terminate, but the time required to rebuild the application given a minor change is considerably less than with a traditional compiler, and from the time you enter the change to the time you start a new debug session for the application may be a matter of a few seconds or a minute, compared to much longer for the same change in a traditional environment.

You can debug multiple processes simultaneously

The IDE lets you start more than one process under debug control, and you can easily switch between running processes to compare, for example, how your application behaves given different inputs. The processes under debug control can also be different executables, which may help you to debug a distributed application.

You can run these multiple processes without cluttering your windowing workspace with countless windows; all debugging windows (other than the windows created by your application) are now views within the IDE, and are organized within pages under a process tab for each process you are debugging.



Start a Program Under Debug Control
Set Breakpoints Before Debugging
Set Breakpoints Within Debug Pages


Limits on Child Process Debugging
Limits on Debugging 16-bit Processes