Skip to content

Instantly share code, notes, and snippets.

@pmichaud
Created June 18, 2012 16:24
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 pmichaud/2949227 to your computer and use it in GitHub Desktop.
Save pmichaud/2949227 to your computer and use it in GitHub Desktop.
pmichaud@kiwi:/zip/perl/rakudo-2012.05$ cat z
#!/bin/bash
for size in 1 10 100 130 135 137 138 139 140 1000 10000;
do
code=$(./perl6 -e "say '+1' x $size")
echo -n "Expressions in input: $size: " ;
time --format=%e -- ./perl6 -e "my \$x = 1$code;" || break;
done
pmichaud@kiwi:/zip/perl/rakudo-2012.05$ sh z
Expressions in input: 1: 0.28
Expressions in input: 10: 0.33
Expressions in input: 100: 0.66
Expressions in input: 130: 0.86
Expressions in input: 135: 0.89
Expressions in input: 137: 0.89
Expressions in input: 138:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment