Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
(Sigh. I just can help myself, can I? Always with the advice... ;-)

Two suggestions for using Benchmark:

  1. If you're using long names for each test, pad the names to the same length with extra spaces on the left. Then your results are much easier to read and compare:
    Hash Exists Hit: 4 wallclock secs @ 1204819.28/s (n=10000 +00) Hash Defined Hit: 3 wallclock secs @ 2173913.04/s (n=10000 +00) Hash Exists Miss: 1 wallclock secs @ 1515151.52/s (n=10000 +00) Hash Defined Miss: 3 wallclock secs @ 1492537.31/s (n=10000 +00) Hash Assigned Miss Truth: 6 wallclock secs @ 1515151.52/s (n=10000 +00) Hash Assigned Hit Equality: 4 wallclock secs @ 1149425.29/s (n=10000 +00) Hash Assigned Hit Truth: 5 wallclock secs @ 970873.79/s (n=100000 +0) Hash Assigned Miss Equality: 6 wallclock secs @ 877192.98/s (n=100000 +0)
  2. Use cmpthese instead of timethese. That adds a handy comparison matrix at the end of your test results (though this suggestion works much better with shorter names):
    Rate HDH HAHE HAME HEH HAMT HDM HAHT HEM HDH 1111111/s -- -0% -4% -21% -24% -28% -30% -39% HAHE 1111111/s 0% -- -4% -21% -24% -28% -30% -39% HAME 1162791/s 5% 5% -- -17% -21% -24% -27% -36% HEH 1408451/s 27% 27% 21% -- -4% -8% -11% -23% HAMT 1470588/s 32% 32% 26% 4% -- -4% -7% -19% HDM 1538462/s 38% 38% 32% 9% 5% -- -3% -15% HAHT 1587302/s 43% 43% 37% 13% 8% 3% -- -13% HEM 1818182/s 64% 64% 56% 29% 24% 18% 15% --

In reply to Benchmark tips by TheDamian
in thread Making a match by Baz

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, 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, 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.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others studying the Monastery: (3)
    As of 2020-09-25 03:10 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?
      If at first I donít succeed, I Ö










      Results (136 votes). Check out past polls.

      Notices?