Fix minor things and improve performance test.