Plunging into .NET Development

Weblog Pieter Gheysens
Microsoft .NET Development - C# - Enterprise Library - Visual Studio 2005 Team System - Compuware DevPartner - ...
 


Wednesday, December 22

JumpStart DevPartner Studio Pro

Yesterday I gave a little demo about DevPartner for my colleagues @ Compuware. Afterwards we talked a bit about the usage of the product and it seemed that some features were not yet discovered by some of the people who attended the session. It might be interesting to share some best practices for those people who are (or will be) working with DevPartner. Everyone who's interested in the product can download an evaluation version at http://nashua.compuware.com/evaluations/

First of all, let me summarize the capabilities of DevPartner Studio Professional : DevPartner Studio provides a variety of programmer productivity features, such as performance profiling, memory analysis, source code analysis, automated error detection, Web and distributed application analysis, and code coverage analysis. DevPartner Studio is a single application that fully integrates with the Visual Studio .NET IDE that provides access to all Functionality.

In this post, I will try to cover some best practices for Performance Analysis.

Performance Analysis

When you run your application during a performance analysis session, DevPartner collects performance data for source files, assemblies, methods, functions and individual lines of code. Results are displayed in the Visual Studio .NET IDE.
  • Exclude system images [Source 100%]

    By default this option is unchecked [Tools > DevPartner > Options ...] and as a result DevPartner collects all system-operations during the run. You should check this option to analyze only your source-code. Otherwise your performance runs will take much longer (really annoying if you are running large applications) and the results won't give you more interesting information about your methods/procedures.


  • Set display options

    Adjust the precision and scale [Tools > DevPartner > Options ...] if necessary.


  • Make use of DevPartner sessions (snapshots)

    During a run you can clear at any time all collected data to the point which the Clear action executes. This feature is really interesting if you want to focus on the performance of a specific action. You can even set a normal breakpoint in your code to clear all data that was gathered before that breakpoint. Data collection then starts from zero after your breakpoint.


  • Display your results in the right format

    Check desired columns and uncheck redundant columns in the result-view.
Remember that the most important thing is not to gather your data, but to analyze/interpret your data. You should learn how you can boost performance in general for your applications. DevPartner lets you drilldown to the true bottlenecks in your applications. Most of the time, low performance will be caused by data-operations : getting data from your database. Limit database-calls, try to process batch-sql-calls where applicable and optimize your stored procedures and/or sql statements. Caching in your application is also a solution for decreasing the number of calls to your database. In my recent project for example, custom caching of data objects into hashtables made a big performance improvement for time-consuming calculations.

In my upcoming post, I'll tackle some other capabilities of DevParnter Studio Professional.

0 Comments:

Post a Comment

Links to this post:

Create a Link

<< Home