add test case and benchmark