[ rev ] separate 1d and 2d implementation