.net - Wrong results in Visual Studio Performance Profiler -


i have used builtin sampling-based performance profiler of vs 2010 in past. highlighted code in code window off couple of lines. might have been due code optimization, profiler said not handle well. other that, worked me (in contrast instrumenting variant)

however, time results plain wrong. instance, there a single line in code (a call method results in db query) accounts 40% of total run time, , found "comment out code bisection" method.

the sampling profiler of vs2012 (and vs2010, double checked) tells me method accounts for 1% (inclusive), i.e. not show in report summary , have search bottom of detail tables find it. cranked sampling frequency in case, no avail.

what throw profiler far off?

i profiling .net 3.5 based project, fair number of dlls. tried profiling in both 'release' , 'debug' mode. no substantial difference.

are in "cpu profiling" mode? in mode blind i/o, , assume db query i/o.

that's why rely on this old surprisingly effective technique. there no such caveats.


Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -