This repository was archived by the owner on Dec 25, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
X64
winscripter edited this page Dec 23, 2024
·
2 revisions
To use the x64 emulator, you should use Machine.X64.Runtime. Note that due to the potential bugs, it's not currently a package on NuGet, but it will be.
Import the namespace:
using Machine.X64.Runtime;
You should primarily use the CpuRuntime class to emulate the CPU.
Emulates the x64 processor in C#.
Constructors:
.ctor(Int32 memorySize, Int32 ioPortCount, Int32 bitness)
Methods:
void RaiseInterrupt(Byte interruptNumber)void Break()void StackPush(UInt64 value)void StackPush(UInt32 value)void StackPush(UInt16 value)UInt64 StackPopU64()UInt32 StackPopU32()UInt16 StackPopU16()void RaiseException(Machine.X64.Runtime.Errors.IErrorRecord record)void RaiseDeviceNotAvailable()void RaiseUnboundIndex()Byte ReadIOPort(Byte index)UInt16 ReadIOPort(UInt16 index)UInt32 ReadIOPort(UInt32 index)UInt64 ReadIOPort(UInt64 index)void RaiseUndefinedOpCode()void RunInMemory(UInt64 physicalAddress)void Run(Int32 numberOfTimes)void RunUntilTrue(Func<Boolean> until)void RunUntilNotBusyOrTrue(Func<Boolean> until)void RunUntilNotBusy()void RunUntilNotBusy(Int32 maxLimit)void LoadProgram(Byte[] program, UInt64 at)void SetRsp(UInt64 rsp)void Use8086Compatibility()void Use8086Compatibility(Boolean use8086Compatibility)
Properties:
Machine.X64.Component.Fpu Fpu { get; set; }Machine.X64.Component.Memory Memory { get; set; }Machine.X64.Component.ProcessorRegisters ProcessorRegisters { get; set; }UInt32 IDTAddress { get; set; }UInt32 IDTLimit { get; set; }Boolean Busy { get; set; }UInt64 CurrentRip { get; set; }Iced.Intel.Instruction LastOrExecutingInstruction { get; set; }Machine.X64.Runtime.Core.Mxcsr Mxcsr { get; set; }Machine.X64.Runtime.InputOutputPort[] IOPorts { get; set; }Byte Cpl { get; }