We don't bite newbies here... much | |
PerlMonks |
Re^17: "Automated" benchmarkingby BrowserUk (Patriarch) |
on Jan 26, 2012 at 10:04 UTC ( [id://950064]=note: print w/replies, xml ) | Need Help?? |
Thanks. That clears things up. (Well mostly:). The answer appears to be something to do with the fact that Win32::Sleep() is a built-in masquerading as an autoloaded module "export". That is to say, you don't have to do use Win32; prior to using Win32::Sleep(). However, if you do use Win32;, then do the profiling, you get just:
I do mean "just". Without the use, it profiles all of the usual things strict; warnings; Dynaloader; Autoloader; Config; Carp; Cwd; etc. etc. But by adding use Win32;, all of that profile trace vanishes, and you get just the above output. Which is cool in a weird sort of way (or weird in a cool sort of way:), but has the bonus that now the counts are as expected. Not totally satisfactory as an explanation in as much as it opens another bunch of questions -- like: why does strict.pm et al no longer get traced? (Regardless of whether the use strict; comes before or after the use Win32; --, but it is enough to satiate my curiosity. As an added bonus, I shall be adding use Win32; to more of my scripts -- at least when profiling, because it stops the profilers profiling all the modules I'm (usually) not interested in seeing. Which both speeds up the profiling and reduces the volume of the output. Curiosity has its upsides sometimes :) Thanks for all your help. With the rise and rise of 'Social' network sites: 'Computers are making people easier to use everyday'
Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
In Section
Seekers of Perl Wisdom
|
|