Please enable JavaScript to view this site.

Performance Validator Help

 

The Analysis tab performs queries on the collected performance data and displays the results.

 

interactiveRead on, or click a part of the image below to jump straight to the help for that area.

 

analysis-tab

 

 

As with many of the tab views, the display is split into two resizable panes.

 

the left side shows a query form and an ordered hierarchical view of the matching functions called in the program's execution

 

The result tree's popup menu provides options to filter data or to examine it in more detail
 

The right side shows the source code view for any function selected on the left

 

 

The Query form

 

The analysis query form lets you search the collected data and the performance statistics for a wide set of criteria.

 

analysis-query-form

 

Setting up the Query Type

 

Query Type instructionStep choose the main feature on which you want to search

 

There are a wide range of options and they fall into four categories:

 

Function information like class, function or file name
 

Performance data like total time, average time or visit count
 

Hotspot queries like most visited or most time consuming
 

Callstack investigation like callstack length, or recursion

 

The full list:

 

analysis-query-type

 

Most of these types are self explanatory or described briefly in the Statistics data but there's a few new ones:

 

Distance to root / leaf instructionStep find function calls at a certain nesting level from the top or the lowest point of the callstack

 

Recursing function instructionStep find any functions that have been called recursively

 

Recursing function depth instructionStep find functions called recursively to a specific depth

 

 

The options underneath the Query Type may change to one of the following to match the corresponding type of query:

 

Class, Function, File or Module instructionStep choose from the drop down list the name you want to search for

 

The drop down is populated with known options from the hook data.

 

This option is disabled if the query type doesn't require a subsequent choice of name.

 

 

Constraining the results

 

The results may be constrained by type of comparison with optional range checking.

 

For function information like class, name, file, these constraints do not apply.

 

For number based queries, including Address, you can limit, invert or box the results

 

Comparison instructionStep choose from the comparison type from the drop down list

 

analysis-comparison-type

 

Range instructionStep enter one or both values to specify a limit or a range, depending on the comparison type

 

For example:

 

< (less than) or == (equals) would need just the one limit.

 
Inside range would need lower and upper bounds specified.

 

 

The analysis results view

 

Query results are shown as an ordered list of trees for every matched function that has been hooked and called.

 

For example, if there are 10 matching results, there will be 10 top level nodes in the tree. Some of these may show child functions, some may not.

 

The query result structure can be likened to taking the Call Tree data, removing all functions above a matching functions, while keeping all functions below.

 

Each result is shown independently of any other, so it's quite likely that some later results may also appear as children of earlier results in the list.

 

Functions are initially ordered by Total Time - the time a function and it's child functions contribute to the total run time.

 

Selecting a function shows its source code on the right hand pane.

 

Double clicking any item will display the function on the Relations tab.

 

note Like the Call Tree view, function timings shown here are for the time spent in the relevant part of the call tree, not a combined total for everywhere that a function may be used.

 

This example shows part of the results when searching for all functions in the class CMainFrame using the example application.

 

Example:

 

The results below show the first 5 most time consuming results when searching for functions in the class CMainFrame using the example application.

 

 

anaysis-tree-results1

 

Expanding the nodes shows that results 3 and 4 above can be found within the children of the first result

 

anaysis-tree-results2

 

 

Analysis result colours

 

The query result tree is coloured using the customisable Hotspot Colours settings that range from 100% down to 0%.

 

hotspot-colours

 

Colours instructionStep choose the way the colour scheme is applied in the tree

 

Parent % instructionStep colouring is based on function time relative to that of its parent's function time

 

In the example below:

 

qsCompFunc is in the 90-100% colour band as it contributed 97.31% of its parent's function time

 

doCombSort is in the 90-100% colour band as it contributed 97.96% of its parent's function time

 

call-tree-cols-total

 

Total % instructionStep colouring is based on function time relative to the total execution time

 

Now in the example:

 

qsCompFunc is in the 50-60% colour band as it contributed 51.29% to the total run time

 

doCombSort is in the 30-40% colour band as it contributed 32.06% to the total run time

 

call-tree-cols-parent

 

No Colour instructionStep black and white display only
 

 

Updating the display

 

On other tabs, it's the Refresh button that updates the display. Here, although the Search button triggers the query again, it essentially does the same thing.

 

Search instructionStep updates the display with the search results - as does the refresh button on the Tools menu and toolbar

 

A search automatically expands the first nodes in the tree and highlights the most time consuming low-level function (hotspot).

 

As there's no auto update here, you'll need to use this Search button to update the display whenever you wish.

 

Collapse / Expand All instructionStep hide or show every node in all the result trees

 

Clear instructionStep removes the results

 

Display... instructionStep displays the Analysis Display Settings dialog

 

 analysis-display-settings-dialog

 

 

Sorting the data

 

The result tree is initially ordered by most time consuming function first (Total Time)

 

Smallest values first instructionStep change the ordering direction of the data

Largest values first instructionStep change the ordering direction of the data

 

note Note that while your application is executing, the sorted data is live. Sorting may not complete correctly as the data may change during the sort. Only when your program has finished executing is the sorted data guaranteed accurate.

 

 

Managing the data being displayed

 

You can't filter out functions by name but there are two ways to change what's displayed in the view.

 

Change the amount of detail shown for each function:

 

Address instructionStep check to show the address in memory for the function

 

Filename instructionStep check to show the file location in which the function was found

 

Modulename instructionStep shows the function's module

 

 

Reduce the scope of the tree by only showing a partial list of results:

 

First N Matches instructionStep restricts the results to a specified number of matches

 

All Matches instructionStep shows all results

 

note You'll need to Search again in order to update the display

 

 

Finding text

 

To find text in the tree, use the Find Dialog where you can search for functions, files and modules.

 

seeAlsoThe source code view has its own Find and Goto dialogs.

 

 

Analysis results menu optionsright_mouse_button

 

The following popup menu is available over the result tree to add filters, examine relations or edit code.

 

Menu actions apply to the function in the tree at the menu-click location.

 

analysis-menu

 

 

right_mouse_buttonMenu options: Previous and next result nodes

 

Functions may appear in the tree more than once if called by different parent functions.

 

Go to Previous Analysis Node for this Function instructionStep jump to the previous instance of this function in any of the result trees

 

b_ctrl +left_mouse_buttonhas the same action

 

Go to Next Analysis Node for this Function instructionStep jump to the next instance of this function in the results

 

b_ctrl +right_mouse_buttonhas the same action

 

If there are no previous or next instances, nothing will happen.

 

 

right_mouse_buttonMenu options: Show in other tabs

 

Go to Call Graph Node instructionStep switch to the Call Graph view where the display will be expanded to show the first match found for the selected function

 

 

right_mouse_buttonMenu options: Go to Call Tree or Graph

 

Go to Call Tree Node instructionStep switch to the Call Tree view where the display will be expanded to show the first match found for the selected function

 

Go to Call Graph Node instructionStep open the Call Graph view at the main entry for the selected function

 

The Call Graph view is similar to the Call Tree, but where a function would appear multiple times, it instead appears once as the main instance and is then linked to from other locations.

 

 

 

right_mouse_buttonMenu options: Function filter (Instrumentation)

 

While the display filter controls visibility of hooked data, instrumentation filters control which functions are hooked in the first place.

 

The function instrumentation filter sub-menu lets you add hook filters at different levels of granularity.

 

statistics-menu-instrumentation-filter

 

note The affect of adding function filters here depends on the current filter settings:

 

If the current filters are set to hook everything, adding new filters will switch to excluding newly selected hooks
 

Otherwise, the current filter will be retained, i.e. hook or don't hook newly selected items  

 

 

The first three options add filters to the Class and Function Filter Settings:

 

By Class instructionStep adds a new filter, excluding the entire class from the results of subsequent sessions
 

By Class and Method instructionStep excludes only the selected function from new sessions
 

By Function instructionStep excludes all matching function names irrespective of their containing class or even if not in a class at all
 

 

The next two, Filename and Directory, are part of the Source Files Filter settings.

 

By FileName instructionStep adds a new filter, excluding all functions in the same file (as the selected item) from the results of subsequent sessions
 

By Directory instructionStep excludes functions in all files in the same directory as the selected function
 

 

Finally, the DLL level is controlled by the Hooked DLLs settings.

 

By DLL instructionStep excludes functions in all files belonging to the same executable or DLL as the selected function
 

 

note Instrumentation filters become effective at the start of the next session. Adding a filter during a session will show the relevant rows in grey so that you can see which files would be filtered, but the performance data will continue to be included for the rest of the current session.

 

 

right_mouse_buttonMenu options: Line timing filter (Instrumentation)

 

Line timing instrumentation filters control which lines are hooked for line timing and are independent of the function filters above.

 

note The affect of adding line timing filters here depends on the current line timing filter settings:

 

If the current filters are set to hook everything, adding new filters will switch to only including newly selected hooks

 

Note that this is the opposite of function filters.
 

Otherwise, the current filter will be retained, i.e. hook or don't hook newly selected items  

 

The line timing instrumentation filter sub-menu lets you add hook filters at three different levels of granularity.

 

Each option add filters to the Line Timing Filter Settings:

 

By Class instructionStep adds a new filter, appending the entire class in the line timing results of subsequent sessions
 

By Class and Method instructionStep include only the selected function in the line timing of new sessions
 

By Function instructionStep includes all matching function names irrespective of their containing class or even if not in a class at all
 

note Instrumentation filters become effective at the start of the next session. Adding a filter during a session will show the relevant rows in grey so that you can see which files would be filtered, but the performance data will continue to be included for the rest of the current session.

 

 

right_mouse_buttonMenu option: Show in Analysis tab

 

While this may already be the Analysis tab, sometimes it can be useful to choose a function from the results and pivot the search to show a new result set:

 

Show in Analysis tab instructionStep choosing any item in the following sub-menu, to perform a new search in the Analysis tab

 

statistics-menu-show-in-analysis

 

For example:

 

Class instructionStep the results show all points in the call tree that match the class of the selected function
 

File name instructionStep shows all points in the call tree that match the file name of the selected function

 

Slower Functions (%) instructionStep shows all functions that are slower than the selected function

 

 

right_mouse_buttonMenu options: Show in Relations tabs

 

Show in Relations tab instructionStep switch to the Relations tab where you can examine functions that either call, or are called by, the selected function

 

Double clicking any item will also display it in the Relations tab.

 

 

right_mouse_buttonMenu options: Remove entry

 

You can hide some entries from the displayed results.

 

However, this is a very temporary action, as a function and its children will only be hidden from view until the next Search.

 

Remove entry instructionStep hides the selected function in the tree

 

Only the selected node is hidden. Other calls to the same function in a different part of the results will remain.

 

 

right_mouse_buttonMenu option: editing source code

 

Edit Source Code... instructionStep opens the default or preferred editor to edit the source code

 

 

right_mouse_buttonMenu options: Expand and collapse

 

The last few menu options expand and collapse parts of the tree.

 

Expand Next Hotspot instructionStep finds the next most significant in the call tree and expands all the callstack nodes to make it visible

 

Collapse / Expand Entry instructionStep close or recursively open the selected function to its full extent

 

Collapse / Expand All instructionStep completely collapse or expand the entire tree

 

 

The file source code view

 

Clicking on a function in the results tree shows that function's source code file in the right hand pane.

 

The source code view is described in detail separately as its behaviour is the same for all views.