Merged VMObject.templates and VMObject.variables

changed pc and sp type to size_t and removed redundant instruction.