memory circular shift operations

and unit tests