Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does not load SOS.dll in VS 2013

The SOS Debugging Extension that I use in VS2010, but now cannot use in VS2013. I guess, I have to any update or some stuff install for VS2013, right?

I try to like below in the Immediate Window;

.load sos

Invalid expression term '.'

.load C:\Windows\Microsoft.NET\Framework\v4.0.30319\SOS.dll

Unexpected character '\'

.load "C:\Windows\Microsoft.NET\Framework\v4.0.30319\SOS.dll"

Unrecognized escape sequence

.load C:\Windows\Microsoft.NET\Framework\v4.0.30319\SOS.dll

Unexpected character '\'

.load C:/Windows/Microsoft.NET/Framework/v4.0.30319/SOS.dll

Invalid expression term '.'

like image 918
bashkan Avatar asked Dec 29 '13 16:12

bashkan


People also ask

Where can I find SOS DLL?

You can find it in C:\WINDOWS\Microsoft.NET\Framework\v4. 0.30319\sos. dll path. To get SOS automatically downloaded you need to have the Microsoft symbol servers set up in the _NT_SYMBOL_PATH environment variable.

What is SOS DLL?

The SOS Debugging Extension (SOS. dll) helps you debug managed programs in Visual Studio and in the Windows debugger (WinDbg.exe) by providing information about the internal Common Language Runtime (CLR) environment. This tool requires your project to have unmanaged debugging enabled.


1 Answers

This feature has been getting brittle since VS2012 and it doesn't exactly look like Microsoft intends to maintain it. Part of the problem appears to be integration of device driver debugging into VS, that's at least the hint I'm getting from this feedback article.

There's a setting that needs to be turned on to get it to recognize the .load command in the first place: Tools + Options, Debugging, General, tick the "Use Managed Compatibility Mode" checkbox. I had turned that off because it had undesirable side-effects.

That still doesn't help on my machine (could be an isolated issue), the command fails with "Error during command: Exception c0000005 occurred at xxxxxxxx". A problem I also had on VS2012. Maybe you'll have better luck, but long term I think it is wise to get familiar with Windbg.

like image 166
Hans Passant Avatar answered Sep 23 '22 19:09

Hans Passant