Download Using Sun WorkShop - Oracle Documentation

Transcript
Graphing a Function
Using the Call Grapher, you can graphically inspect the relationships of the functions
in programs using ANSI C, C++, and Fortran. You can display the functions that
either call or are called by one or more selected functions.
You must have a source browsing database to view function relationships (see
“Source Browsing Databases” on page 28).
Note - You can graph virtual functions, but you should be aware that Sun WorkShop
cannot determine the actual function that would be called. For example: If main calls
b::d(), a virtual function that could actually call b1::d() or b2::d(), Sun
WorkShop cannot tell which function is called. The graph shows main calling b::d(),
but no connection between main and b1::d() or main and b2::d().
Call Graph Window
The Call Graph window provides a graphic representation of the call relationship of
functions and subroutines. Figure 3–5 shows the Call Graph window.
To change the colors used for node background, graph pane background, node
border, node text, and arrows between nodes in the Call Graph window, edit the
WORKSHOP resource file (see “Call Graph and Class Graph Window Colors” on page
131). Any color changes you make apply to both the Call Graph and Class Graph
windows (see “Class Graph Window” on page 40).
Browsing Source Code
37