Steve's Blog

Random comments on .NET, debugging, and more.

Introducing SPT for .NET 4.5

This has been a post long in the making.  I’d written this in December/January as a complete re-do of SPT for .NET 4.0,  (Side Note: Interestingly enough, in the mean time MS released ClrMD, which is similar to the direction I was going, but still significantly different (I’m focusing more on a lower level interface to be plugged into WinDBG, ClrMD is focused more on a managed vector).) but never released it publically.

I’ve decided this time around to release the entire library under the GPL.  For anyone who would like to use this in commercial software, contact me and we can probably work something out.  I’ll be pushing the full source tree to my github account shortly.  https://github.com/steveniemitz/SDbgExt2.

The initial release supports most of the original SPT commands:

  • DumpAspNetRequests
  • DumpDictionary
  • DumpSqlConnectionPools (aka !sqlblame)
  • DumpThreadPoolQueues
  • FindHttpContext
  • GetDelegateMethod

In the next few days, I’ll be posting more about SDbgExt2 (and the WinDBG extension, SPT), it’s inner workings, and how the new IXCLRDataProcess3 interface works.  My main design goals for SDbgExt2 were:

  • Easily support a managed wrapper interface
  • Separate the core debugging interface from the “value add” interface.  As you can see, SDbgCore is a fairly small static library, which SPT links against.
  • Provide a cleaner code base which is easier to maintain and enhance in the future, as well as which abstracts IXCLRDataProcess as much as possible.
  • Have near-100% code coverage via unit tests from the start.  This is mostly achieved with pre-canned mini-dumps which the unit tests can operate on.  (Side note: for now I’m not releasing the mini-dumps as they contain machine-specific data, I may in the future release them if I can prove they contain no personal data, but for now the unit tests are being released as more of a reference guide.)

I’m also posting pre-compiled, ready to run SPT.dll binaries for use in WinDBG (or elsewhere).

Download here:  x86 / x64

As always, feel free to post here or email me if you have any questions / comments.

blog comments powered by Disqus