Dela via


IntelliTrace with Call Information

This topic applies to Visual Studio 2010 Ultimate only.

By default, IntelliTrace collects information for specified IntelliTrace events. When your application enters break mode, you can use the IntelliTrace Events view of the IntelliTrace window to see the events that have been collected. You can use the IntelliTrace Events view to find IntelliTrace information about a file-open event, for example, or an exception or a .NET Framework event.

Sometimes, you might need more information than the IntelliTrace Events view provides. When you need more detailed information, you can choose to collect call information in addition to IntelliTrace events. Call information includes the name of the function, method, or procedure being called, the parameters passed to it, and any return value that is passed back.

Collecting call information has a larger performance overhead than collecting IntelliTrace events. Collecting call information also increases the size of the log files that store collected information on your hard disk. You are unlikely to notice any slowdown in your application when you collect IntelliTrace events only, but might notice some slowdown when you collect call information. To minimize this slowdown, you can choose to collect call information for only those modules that you are interested in and ignore other modules.

Collecting call information

To view IntelliTrace call information, you must begin to collect call information at the start of the debug session. If you enable the collecting of call information during a debug session, you must restart the debug session for the change to take effect.

To configure IntelliTrace to collect call information

  1. On the Tools menu, click Options.

  2. In the Options dialog box, click IntelliTrace.

  3. Under Enable IntelliTrace, click IntelliTrace events and call information.

    A warning appears, informing you that this change does not take effect until the start of the next debug session.

  4. You can limit IntelliTrace collection to only those modules you are interested in. This step is optional but will improve performance and minimize the size of the trade debugging log file.

    1. Under the IntelliTrace node, click Modules.

    2. In the Modules page, click Collect data from all modules except for the following or Collect data from only the following modules.

    3. To remove a module from the list, highlight the module name and click Remove.

    4. To add a module to the list, highlight the module name and click Add, then add the module name in the Add a pattern dialog box. To add multiple modules, you can use the wildcard character * as a prefix or a suffix.

    5. To restore the modules list to its original default contents, click Restore.

  5. Collecting call information also increases the size of the trace debugging log file on disk. At this point, you might want to verify the maximum size of the log file.

    1. Under the IntelliTrace node, click Advanced.

    2. If you want to change the current setting, click the Maximum amount of disk space for each recording drop-down list.

  6. Click OK.

Viewing call information

When IntelliTrace collects call information, you can view the call information in the IntelliTrace window. The call information is displayed in the Calls view.

To display the Calls view

  • In the toolbar at the top of the IntelliTrace window, click the Show Calls View icon.

The Calls view looks like this:

Debug History Window Inverted Stack View

The Calls view provides a hierarchical way of viewing and navigating calls and IntelliTrace events.

The Calls view resembles an inverted version of the debugger Call Stack window. In the Call Stack window, the current call is located on the top. In the Calls view, it is located on the bottom.

When debugging with IntelliTrace, current call means the call that was current in the time context you are viewing. It is not necessarily current in real time.

Indented below the current call, the Calls view shows a list of calls that are made from the current call and IntelliTrace events that occur during the current call.

You can click any call to make that the current call. You can also click an IntelliTrace event or call site that is indented underneath the current call, to navigate to that event or call site. You can double-click a call site to navigate into that call.

For more information, see Navigating with IntelliTrace.

Other navigation tools

IntelliTrace events and call information enables some other navigation tools, in addition to the Calls View:

  • The navigation gutter appears in the source window, between the standard debugging gutter and the margin. The navigation gutter enables you to step forward and back between calls, go to the previous or next call or IntelliTrace event, return to live mode, or set the debugging context on a call frame.

  • The IntelliTrace search feature appears in shortcut menu in a source window. You can use this feature to navigate to a specific instance of a call.

For more information about how to use these tools, see Navigating with IntelliTrace.

See Also

Concepts

Debugging Code Faster with IntelliTrace

Collecting IntelliTrace Information