Added speed regression test. Fixes #49