c++/simple_vm: remove state redundancy