if your subs can be broadly categorised as disk-intensive, memory-intensive, cpu-intensive you can see which of these 3 groups varies substantially against the others (standard deviation is an indication of variation). For example that YAML* sub being invariant in all three runs while others with similar run-times were not. Perhaps perlperf can help you.

Also, are you 100% sure that your program is deterministic? Are there no random choices? For example, even iterating over the keys of a hash is non-deterministic. What if the algorithm benefits if the longer keys are processed first? Also, regex are also working internally with non-deterministic algorithms (that's my understanding on when a regex consists of a "choice") and therefore may show variability in termination (see https://stackoverflow.com/questions/36420517/is-it-faster-to-use-alternation-than-subsequent-replacements-in-regular-expressi).

If you want to exclude the possibility of non-deterministic behaviour and other program-specific factors, start by doing some benchmarks yourself. See Benchmark on how to profile subs yourself easily.

People from my social circle constantly harass me with their windows-10 too-slow problems. Sometimes I find that they have background updates sucking up resources (sometimes it's a cryptic generic windows process name).

bw, bliako


In reply to Re^3: nytprof Profiler gives diverse results by bliako
in thread nytprof Profiler gives diverse results by boleary

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.