No matter how much Microsoft builds into the Visual Studio IDE, there will
always be room for third parties to add more capabilities. And fortunately the
extensibility hooks are there for other products to blend themselves with Visual
Studio. Thus it is that DevPartner Studio can integrate itself very tightly
indeed with Visual Studio 2005, bringing additional tools for the serious
software developer to your fingertips. You get an extra menu and an extra
toolbar, as well as new tool windows and views of your code, to help you quickly
analyze your code and keep it running at its best. The tools here are clearly
directed at people struggling with large and complex code bases, and some of
them are going to be most useful to C++ developers. Here's a look at what
you'll find inside the box.
I think my own favorite portion of the product are the static code analysis
tools. This may be just because I've recently been trying to understand a large
chunk of poorly-structured code from some other overpaid consultant, but the
execution here is the best I've seen. DevPartner Studio will deliver a full
rules-based analysis of the code, and you can manage the rules database with a
separate utility if the included 600+ rules aren't enough for you. There's also
an excellent graphical call graph analyzer that lets you see what is called from
where and that can quickly jump into the source code that you're tracing.
Error detection is one of the flagship capabilities here, though it's aimed
mainly at C++ developers. DevPartner Studio will monitor your running code to
detect a wide variety of errors at runtime: pointer and leak errors, read and
write overflows, deadlock errors, API and COM argument errors, and so on. After
running your app you can see exactly what went wrong and trace it back quickly
to the offending line of code.
All developers will probably appreciate the graphical code coverage and
memory analysis tools here. Again, they work by monitoring your application as
you execute it in the debugger. The code coverage tool will show you, down to
the method, which code you exercised when you ran the application. There are
both tabular and graphical summaries, which are good for helping you make sense
of the overwhelming amount of information this can provide on an extended run.
You can also configure things to collect coverage data from both the client and
server sides of distributed applications. Similarly, the memory tools will show
you graphically just how much memory your application is taking up as it runs,
and which objects are occupying that memory. Although .NET does its own garbage
collection, there are ways to optimize your memory use, and the chapter in the
manual on using this tool shows you how you can track down and correct some
problems in your code.
Finally, there's a thorough code profiler (they call it Performance Analysis)
here. Again, you can get a tabular or graphical list of what's taking up CPU
time, and you can easily drill into the hot spots to locate problem code. You
can collect data from managed code or unmanaged code (with an instrumentation
step), and also correlate performance data across multiple processes, which is
handy for analyzing what's going on with distributed applications. There's also
a Performance Expert which takes a much higher-level view of what's going on in
your program to help find trouble areas without making you wade through all the
individual detailed data. Performance Expert can help locate issues with CPU
performance, file or network bound I/O processes, or synchronization wait times
for you to inspect further.
One nice touch is that none of this information is transient - you can save
all of the analyses to separate files maintained by DevPartner Studio for later
review and comparison with future versions of the application. I could also see
using this to communicate between parts of a distributed team; you could record
a performance analysis session, for example, and then pass it off to someone
with more or different expertise for a closer look.
Version 8.1 builds on this base by adding some integration with Visual Studio Team
System. If you're looking at a problem in the DevPartner code review module, or
a violation of a naming standard, or a method in the Performance Expert or Performance
Analysis or code coverage or memory analysis, a single mouse click will submit the
relevant information as a VSTS work item, prepopulated with all of the information
from DevPartner. Thus you can use DevPartner as a way to find problems, and then
manage those problems through the shared VSTS back end. 8.1 also adds a tutorial
on customizing code review rules and additional examples of customizing rules with
regular expressions, as well as an embeddable agent that you can ship with your
applications to collect runtime configuration information on the systems where those
applications are deployed.
With its pricing, DevPartner Studio is largely aimed at the corporate market,
of course. But if you're trying to tame a large and unruly codebase, there are
very few other tools that will scale as well as this one. You can learn more and
sign up for an evaluation at Compuware's Web site.