Analyzing performance with a call graph model

You use the PowerScript functions and PowerBuilder objects listed in Table 33-8 to analyze the performance of an application.

Table 33-8: Functions for analyzing performance

Use this function

With this object

To do this

SetTraceFileName

Profiling

Set the name of the trace file to be analyzed.

BuildModel

Profiling

Build a call graph model based on the trace file. You can pass optional parameters that let you track the progress of the build.

RoutineList

Profiling and ProfileClass

Get a list of routines in the model or in a class.

ClassList

Profiling

Get a list of classes in the model.

SystemRoutine

Profiling

Get the name of the routine node that represents the root of the model.

IncomingCallList

ProfileRoutine

Get a list of routines that called a specific routine.

OutgoingCallList

ProfileRoutine and ProfileLine

Get a list of routines called by a specific routine or from a specific line.

LineList

ProfileRoutine

Get a list of lines in the routine in line order.

DestroyModel

Profiling

Destroy the current performance analysis model and all the objects associated with it.

Each of these functions returns a value of the enumerated datatype ErrorReturn. The objects contain information such as the number of times a line or routine was executed, and the amount of time spent in a line or routine and in any routines called from that line or routine.