My Code Does What?!

Software performance, profiling, and design

See The Profiler At PDC2008

Steve Carroll, development lead for the Visual Studio Profiler, will be at PDC2008 next week giving a presentation on the profiler: What: TL24: Improving .NET Application Performance and Scalability When: Wednesday, October 29th, 1:15pm – 2:30pm Where: Room 153 Abstract: “Performance must be considered in each step of the development lifecycle. See how to integrate… Read more

Visual Studio Profiler: Found A Bug? Have A Suggestion?

The profiler is not flawless.  We work hard every day to improve it, however, and we’re always listening to and considering your feedback.  The profiler exists to help you, so if you feel it has shortcomings or if it fails to fully address your scenario, please let us know.  The more we hear from you,… Read more

VS2008 SP1 Website Profiling Bug And Workaround

Visual Studio 2008 Service Pack 1, while fixing many profiling bugs, has also unfortunately introduced an issue with website profiling.  If you have a website project created with a pre-SP1 version of Visual Studio and then try to profile it using instrumentation with VS2008 SP1, you might run into a rather vague error: “Value does… Read more

Visual Studio 2008 Service Pack 1 Released To The World!

After months of development and some grueling bug fixes, we released the VS2008 SP1 patch to the web this morning.  You can check out more details in the readme.  For the profiler, we fixed a number of bugs including: Adding support for instrumenting 64-bit managed C++ applications Improved instrumentation experience with precompiled websites Shipping the… Read more

Walkthrough: Profiling With Automated Tests

When doing performance investigations, we recommend having some well-defined scenario in mind in order to increase the reproducibility of your issue and increase the consistency of profiling data collected.  This approach is similar in spirit to creating the smallest self-contained repro possible when debugging.  When diagnosing any complex system, limiting the variables involved is a… Read more

Sample Profiling And Stdin

Some command-line applications can read from stdin for use as program input.  The canonical example of this is sort.exe which sorts the list of strings given to it and prints it back out to the console: C:\Temp> type letters.txt m z a C:\Temp> sort < letters.txt a m z Sample profiling an application that reads… Read more

Excluding Small Functions From Instrumentation

In Visual Studio 2008, we added a feature to exclude small functions from instrumentation.  A small function is a function that has very few instructions and makes no function calls (i.e. it’s a leaf).  The idea behind this feature is that small functions are unlikely to be significant in the overall profile of your application,… Read more

What code path is allocating the most bytes for a type?

In Visual Studio 2008, we added the ability to quickly determine the most expensive call stack in your application.  In profiler parlance, the “most expensive call stack” is known as the “hot path”.  What do we mean by “expensive”?  “Expensive” is whatever measure you want it to be: number of samples in a function, time… Read more