Skip to content

Instantly share code, notes, and snippets.

@Whateverable
Created March 10, 2021 19:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Whateverable/27ebba85f0a5cf575230d5fdc027241f to your computer and use it in GitHub Desktop.
Save Whateverable/27ebba85f0a5cf575230d5fdc027241f to your computer and use it in GitHub Desktop.
benchable6
compare HEAD use nqp; my num $n = nqp::time_n(); my $i; $i := ($n * 1000).Int for ^100_000; ||| use nqp; my num $n = nqp::time_n(); my $i; $i := ($n * 1000e0).Int for ^100_000;;
¦HEAD: «Benchmark:
Timing 10 iterations of 0, 1...
0: 0.660 wallclock secs (0.660 usr 0.008 sys 0.668 cpu) @ 15.156/s (n=10)
(warning: too few iterations for a reliable count)
1: 0.273 wallclock secs (0.268 usr 0.000 sys 0.268 cpu) @ 36.644/s (n=10)
(warning: too few iterations for a reliable count)
O---O--------O------O------O
| | Rate | 0 | 1 |
O===O========O======O======O
| 0 | 15.2/s | -- | 142% |
| 1 | 36.6/s | -59% | -- |
O---O--------O------O------O
»
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment