I suggest you ...

Disable Framework optimization when Debugging through the Framework

It is now relatively easy to step through .NET Runtime framework code by turning off 'Just My Code' and enabling Microsoft symbol servers. However the code that you are stepping through is OPTIMIZED and thus the debugging experience is often bad.

This does not have to be. As explained here

https://blogs.msdn.microsoft.com/vancem/2017/12/20/update-debugging-through-the-net-core-framework-v2-0-3-windows/

You can set an environment variable COMPLUS_ZapDisable (which forces JIT compilation of the framework) and then also set the Visual Studio 'Supress JIT Optimization' you force THAT PROCESS to run with non-optimized framework code.

This is pretty valuable, but getting there requires a multi-step process and knowledge that many people will never discover.

Instead Visual Studio should make an option for this (Disable Framework Optimziation), and/or make an option (Debug Framework) that with one selection does all the things necessary (turns off Just my code, selects Microsoft symbol server, suppresses JIT compilation and sets the COMPLUS_ZapDisabled option).

Now some of these setting have important side-effects, so there should be good help docs and maybe even dialog warnings, but the key goal is to make debugging through the framework relatively easy and DISCOVERABLE

17 votes
Vote
Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)
You have left! (?) (thinking…)
Vance Morrison shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

0 comments

Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)
Submitting...

Feedback and Knowledge Base