On Wed, Mar 21, 2012 at 6:32 PM, Juan Manuel Cabo <span dir="ltr"><<a href="mailto:juanmanuel.cabo@gmail.com">juanmanuel.cabo@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
This is a small util I wrote in D which is like the unix<br>
'time' command but can repeat the command N times and show<br>
median, average, standard deviation, minimum and maximum.<br>
<br>
As you all know, it is not proper to conclude that<br>
a program is faster than another program by running<br>
them just once.<br>
<br>
It's BOOST and is in github:<br>
<br>
    <a href="https://github.com/jmcabo/avgtime" target="_blank">https://github.com/jmcabo/<u></u>avgtime</a><br>
<br>
Example:<br>
<br>
<br>
    avgtime -r 10 -q ls -lR /etc<br>
<br>
    ------------------------<br>
    Total time (ms): 933.742<br>
    Repetitions    : 10<br>
    Median time    : 90.505<br>
    Avg time       : 93.3742<br>
    Std dev.       : 4.66808<br>
    Minimum        : 88.732<br>
    Maximum        : 101.225<br>
<br>
The -q argument pipes stderr and stdout of the program<br>
under test to /dev/null<br>
<br>
I put more info in the github page.<br>
<br>
<br>
HAVE FUN!!<span class="HOEnZb"><font color="#888888"><br>
<br>
--jm<br>
<br>
<br>
</font></span></blockquote></div><br><div>Nice tool.  I used it here: <a href="http://www.reddit.com/r/programming/comments/rif9x/uniform_function_call_syntax_for_the_d/c46bjs7?context=2">http://www.reddit.com/r/programming/comments/rif9x/uniform_function_call_syntax_for_the_d/c46bjs7?context=2</a></div>
<div><br></div><div>It'd be neat if it could create comparison statistics between the execution of two different programs so you could compare the performance of changes or alternative approaches to the same problem as I was doing.</div>
<div><br></div><div>Regards,</div><div>Brad Anderson</div>