[wip] re-arranging and allowing multiple threads