My C# program should execute an asynchronous task 30 times per second.
The program performs well as a standalone windows application.
But when it runs in debug mode in Visual Studio 2013 Professional environment the perfomance is very poor - just 5 tasks per second, even if there're no breakpoints in the code whatsoever.
Is slow debugging a "feature" of the VS.Net 2013 and is there a way to debug time critical C# apps?
Thank You user1720293 for the idea about logging. The main reason for the huge perfomance drop was in logging to console through log4net.Appender.ConsoleAppender
. After commenting out a line in the configuration file the problem has gone
<root>
<level value="DEBUG"/>
<!-- here's the source of the problem
<appender-ref ref="ConsoleAppender"/>
-->
<appender-ref ref="RollingFile"/>
</root>
I'd try eliminating a few things by: Removing all watch items Hiding the locals, autos window etc
Are you tracing out a lot of text? You could also try not doing that and see if it makes a difference.
Is visual studio left alone by your anti-virus software?
If it isn't pure c# code and c++ is involved anywhere then debugging performance is poor.
None of this is Visual Studio 13 specific advice. Did you previously run this code ok on 2012 or 2010?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With