Wednesday, February 03, 2010

Creating a Quick Windbg Pseudo Debugger Extension - Part I

Problem

Quick way to script, format, group, parse and automate some debugging task[s].
If you ever wish that the debugger would had x,y or z command or debugger extension?
The learning curve and the time to create a simple debugger extension can be challenging for the most part.
Sometimes the debugger scripting may feel short in functionality every now and then.

Solution

Create a console application that is able to receive input and parameter data from windbg, inside the application be able to slide and dice the data using your preferred programming language that you are most familiar with and the ability to display back the data in the debuggers output window.

From windbg this can be done via the .shell command to call and pass parameter and inputs to your pseudo debugger console application, inside your app you can access the past arguments or parameter via the args[] parameter, just like any other command line arguments,  the input data from windbg can be accessed via the std io input stream.

Let’s say that you want to create a debugger extension that groups the top n frames on every thread and report back the results.

Read more: Tepache Debug

Posted via email from jasper22's posterous