added compiler & emulator code