imported vm
Code generation and final fixes