Software implementation of sc-machine