VM cleanup: removed unused methods and made as much as possible fields final. Moved VMFactory to the same package.