[Vm-dev] rearchitecting the FFI implementation for reentrancy