public VirtualMachine(Assembly file) { Assembly = file; Register = new RegisterCollection(this); Stack = new Stack(); ScanInstructions(); PortMappedDeviceManager.ScanDevices(); InterruptTable.ScanHandlers(); ErrorTable.Add(0x1, "The Register is protected"); //ToDo: add ErrorAttribute to Instructions }
public override void Invoke(AsmCommand cmd, VirtualMachine vm) { var interrupt = (int)cmd[0]; InterruptTable.Interrupt(interrupt, vm); }