<div dir="ltr">Hi Martin,<div><br></div><div>You won't find a general purpose benchmarking framework suitable for all tasks but there are plenty of examples:</div><div><br></div><div>* <a href="http://release.softlab.ntua.gr/bencherl/">http://release.softlab.ntua.gr/bencherl/</a> - targets scalability</div><div>* <a href="https://github.com/gar1t/erlang-bench">https://github.com/gar1t/erlang-bench</a> - Garrett uses erlang scripts for his</div><div>* <a href="https://github.com/extend/horse">https://github.com/extend/horse</a> - Loïc's horse [ glad i waited a second before responding... ]</div><div><br></div><div>For small or microbenchmarks there's also HDR histogram which will give fairly extensive</div><div>statistics and allows compensating for coordinated omission for latency sensitive tests if</div><div>that is relevant:</div><div><br></div><div><a href="https://github.com/hdrhistogram/hdr_histogram_erl">https://github.com/hdrhistogram/hdr_histogram_erl</a><br></div><div><br></div><div>Cheers,</div><div><br></div><div>Darach.</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Apr 7, 2015 at 9:48 AM, Martin Karlsson <span dir="ltr"><<a href="mailto:martink@securemedia.co.nz" target="_blank">martink@securemedia.co.nz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hello,</div><div><br></div><div>I want to benchmark individual functions to see how they perform. I've looked around for some library or framework which provides a  repeatable and structured way of doing benchmarking (much like eunit and common tests do for unit and integration tests) but haven't found anything on a micro-level.</div><div><br></div><div>Currently I have an ad-hoc collection of test functions wrapping the function under test in timer:tc but as mentioned looking for something more structured with proper reporting. Before writing it myself I wonder if there is anything out there already doing this?</div><div><br></div><div>Ideally doing:</div><div><br></div><div>$ make benchmark </div><div>or</div><div>$ rebar benchmark</div><div><br></div><div>would run the benchmark tests and output a nice report.</div><div><br></div><div>I've played with golangs benchmark utilities in the testing package (<a href="http://golang.org/pkg/testing/" target="_blank">http://golang.org/pkg/testing/</a>) and found it quite useful and wonder if there is an erlang equivalent?</div><div><br></div><div>Perhaps this is trivial to write in a normal eunit/ct test together with timer:tc or fprof or something and if so I'd be happy to get any pointers on where to start.</div><div><br></div><div><br></div><div>Cheers,</div><div>Martin</div></div>
<br>_______________________________________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" target="_blank">http://erlang.org/mailman/listinfo/erlang-questions</a><br>
<br></blockquote></div><br></div>