I would like to measure the performance of some blocks of code in my winforms C # application. In particular, I want to measure regression / performance improvement after some code restructuring.
So far I have seen System.Diagnostics.Stopwatch . However, I want to avoid entering the dimension code into my classes, I would rather separate the dimension from the actual code.
As for debugging, you can set breakpoints on several lines of code and "jump" from one to another using "Continue execution", I imagine something like this for measurement: Mark lines of code and make Visual Studio display the time elapsed from one to the other.
Is there a free function / add-in in this direction?
source share