Now Available: Psscor4 – Debugger Extension for .NET 4.0


I am very happy to announce that Psscor4 is now available for download.  You can download it from:

Psscor4 Managed-Code Debugging Extension for WinDbg

This should have the same functionality as Psscor2 does but it works against the .NET 4.0 Framework.  Please let me know if you run into any problems downloading or using this extension.  I would also love to know if you have any feature requests for it.

Comments (11)

  1. Shruti says:

    I downloaded the component and tried to load it using teh command .load <psscor4.dll location> in windbg.exe. After doing .load, I could not find the dll in the list of the loaded modules as listed by lmf. Also !help does not yield any output

    I made sure I am using teh correct architecture. Is there anything I am missing?

    Shruti

  2. tomchris says:

    This is a debugger extension so it won't show up in loaded modules.  It should show up in:

    .chain

    That shows loaded debugger extensions.

    You can try running !eeversion to see if it is loaded correctly and working.

  3. Gaël says:

    Hi Tom,

    When I use PSSCOR4 I get the following output for DumpHeap :

    ——

    0:004> !dumpheap -type Exception

    Loading the heap objects into our cache.

    Address       MT     Size

    01ca1024 5392fdc4       84    0 System.Exception

    01ca1024 5392fdc4       84    

    01ca1078 5392ff08       84    0 System.OutOfMemoryException

    01ca1078 5392ff08       84    

    01ca10cc 5392ff54       84    0 System.StackOverflowException

    01ca10cc 5392ff54       84    

    01ca1120 5392ffa0       84    0 System.ExecutionEngineException

    01ca1120 5392ffa0       84    

    01ca1174 5392ffec       84    0 System.Threading.ThreadAbortException

    01ca1174 5392ffec       84    

    01ca11c8 5392ffec       84    0 System.Threading.ThreadAbortException

    01ca11c8 5392ffec       84    

    0:004> !dumpheap -type Exception -short

    01ca1024

    01ca1024

    01ca1078

    01ca1078

    01ca10cc

    01ca10cc

    01ca1120

    01ca1120

    01ca1174

    01ca1174

    01ca11c8

    01ca11c8

    ——

    While I'm still getting the expected output from the standard SOS :

    ——

    0:004> !dumpheap -type Exception

    Address       MT     Size

    01ca1024 5392fdc4       84    

    01ca1078 5392ff08       84    

    01ca10cc 5392ff54       84    

    01ca1120 5392ffa0       84    

    01ca1174 5392ffec       84    

    01ca11c8 5392ffec       84    

    total 0 objects

    Statistics:

         MT    Count    TotalSize Class Name

    5392ffa0        1           84 System.ExecutionEngineException

    5392ff54        1           84 System.StackOverflowException

    5392ff08        1           84 System.OutOfMemoryException

    5392fdc4        1           84 System.Exception

    5392ffec        2          168 System.Threading.ThreadAbortException

    Total 6 objects

    0:004> !dumpheap -type Exception -short

    01ca1024

    01ca1078

    01ca10cc

    01ca1120

    01ca1174

    01ca11c8

    ——

    This is a bit surprising, compared to the output from PSSCOR2 :

    ——

    0:004> !dumpheap -type *Exception

    Loading the heap objects into our cache.

    Address       MT     Size

    01cd1024 57800d94       72    0 System.OutOfMemoryException

    01cd106c 57800e24       72    0 System.StackOverflowException

    01cd10b4 57800eb4       72    0 System.ExecutionEngineException

    01cd10fc 57800f44       72    0 System.Threading.ThreadAbortException

    01cd1144 57800f44       72    0 System.Threading.ThreadAbortException

    0:004> !dumpheap -type *Exception -short

    01cd1024

    01cd106c

    01cd10b4

    01cd10fc

    01cd1144

    ——

    It happens on different systems and different .NET 4 applications (x86 and x64).

    Is this the expected output for DumpHeap in PSSCOR4 ?

  4. tomchris says:

    You shouldn't see the lines being displayed twice.  I will look into that and update here with what I find out. Are you debugging a live process?

  5. cscoq says:

    The behavior is the same for live and dump debugging.

  6. Happy says:

    Woohoo. I've been waiting for this since .NET 4.0 was released. Good see it finally!

  7. Duojiao Yan says:

    Will there be a version to support .NET 4.5?

  8. tomchris says:

    Duojiao,

    I am not sure as of right now.  I have actually moved on to work with Azure and one of my co-workers now owns psscor.  I will check with him but I don't have an update at this time.

  9. Steven Cohn says:

    Is there an update for .NET 4.5?  

    I have VS 2012 with .NET 4.5 installed on a 64-bit Windows 7 Ultimate machine.  I have two issues, regardless of target program or bitness (32, 64, Any).  All programs are written in C# with VS 2012.

    First, the CLR doesn't seem to be loading, it's module is marked as "(deferred)".  I can fix this by using ".reload /f" but I shouldn't need to.  Is this because of the checksum failures shown below?  What is the cause of these failures?  

    Second, while I can use SOS.dll and SOSEX.dll without issues, PSSCOR4 doesn't seem to work – any commands that interrogate the GC heap fail with the output shown below.

    Am I correct is assuming PSSCOR4 needs to be updated for .NET 4.5?  If so, do you know where/when I can find it?

    Thanks!

    0:006]] .loadby sos clr

    Unable to find module 'clr'

    0:006]] .reload /f

    Reloading current modules

    .*** WARNING: Unable to verify checksum for CookieChipper.exe

    .*** ERROR: Symbol file could not be found.  Defaulted to export symbols for C:Program FilesBonjourmdnsNSP.dll –

    *** WARNING: Unable to verify checksum for C:WindowsassemblyNativeImages_v4.0.30319_64mscorlibbbf179f2fc6d84bf78d9e319f9754690mscorlib.ni.dll

    ……………*** ERROR: Symbol file could not be found.  Defaulted to export symbols for C:Program FilesCommon FilesMicrosoft SharedWindows LiveWLIDNSP.DLL –

    …………………………

    0:006> !dumpheap -stat

    No export dumpheap found

    0:006> .loadby psscor4 clr

    0:006> !dumpheap -stat

    The garbage collector data structures are not in a valid state for traversal.

    It is either in the "plan phase," where objects are being moved around, or

    we are at the initialization or shutdown of the gc heap. Commands related to

    displaying, finding or traversing objects as well as gc heap segments may not

    work properly. !dumpheap and !verifyheap may incorrectly complain of heap

    consistency errors.

    Error requesting GC Heap data

    Unable to build snapshot of the garbage collector state

  10. Zverev Eugene says:

    Hi

    Any news on the psscor release for .NET 4.5?

  11. tomchris says:

    Unfortunately not at this time, it is being worked on, but no updates as of now.