Tip #107 Did you know … How to improve debugging performance for MVC2 application in Visual Studio 2010 Ultimate?

VS2010 Ultimate included IntelliTrace functionality by default.  IntelliTrace captures events (e.g. exceptions), and can affect performance of debugging. The typical performance hit is about 5% in the default mode (collection can be increased to collect method calls and parameters which can have up to a 15x hit). However this is completely dependent on what events and how many are occurring. For example, the MVC2 framework uses exceptions for control flow (hundreds can occur when loading a web page), and so launching an MVC app with IntelliTrace enabled runs significantly slower because a call stack is captured for every exception. 

IntellliTrace is however not the debugger, and can be turned off (Tools -> Options -> Intellitrace) if this is causing too much of a problem.

image

From my own machine, I downloaded MVC 2 application Orchard source 0.5.144.zip from http://orchard.codeplex.com/, and setup it using the compact database after running it.  When I do F5 with IntelliTrace on by default, the start up process took about 14 seconds.  When I do F5 with IntelliTrace disabled, the start up process took about 9 to 10 seconds.

Hope this helps you to debug faster if you don’t need IntelliTrace when debugging your MVC2 application.

- Xinyang Qiu | Web Platform and Tools Team

No Comments