Timing Code Execution
-
I need to time how long certain methods are taking to run to a very fine level. Too fine for using DateTime and TimeSpan. Does anyone know of any tools that i can use to analyse which methods are bottlenecks? Thanks
-
I need to time how long certain methods are taking to run to a very fine level. Too fine for using DateTime and TimeSpan. Does anyone know of any tools that i can use to analyse which methods are bottlenecks? Thanks
I'm working on the same thing right now. System.Diagnostics provides access to the performance counters. That's all I can since I just looked at ten seconds ago. When all else fails, there's always delusion. - Conan O'Brien
-
I need to time how long certain methods are taking to run to a very fine level. Too fine for using DateTime and TimeSpan. Does anyone know of any tools that i can use to analyse which methods are bottlenecks? Thanks
It's exceedingly primitive, but combinations of System.Debug.Trace.WriteLines in conjunction with calls to System.Environment.TickCount have always served me well...just grab the tickcount into a long variable at the beginning of a method, and difference it with the current tickcount at the end of the method, then dump the output to the trace. Jeremy Kimball
-
I need to time how long certain methods are taking to run to a very fine level. Too fine for using DateTime and TimeSpan. Does anyone know of any tools that i can use to analyse which methods are bottlenecks? Thanks
Thanks for the replies guys. I actually found a very useful article here on CodeProject which may be of interest? Can be found at: http://www.codeproject.com/useritems/highperformancetimercshar.asp?target=timing Thanks again.
-
Thanks for the replies guys. I actually found a very useful article here on CodeProject which may be of interest? Can be found at: http://www.codeproject.com/useritems/highperformancetimercshar.asp?target=timing Thanks again.
Use the FREE .NET Profiler from www.numega.com [^] -- - Free Windows-based CMS: www.zeta-software.de/enu/producer/freeware/download.html - See me: www.magerquark.de