Working on refactoring into direct-threaded code execution