mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-31 13:21:05 +00:00
29 lines
No EOL
1.1 KiB
C#
29 lines
No EOL
1.1 KiB
C#
using System;
|
|
using System.Linq;
|
|
|
|
namespace Indy.IL2CPU.Assembler.X86 {
|
|
[OpCode("pop")]
|
|
public class Pop: InstructionWithDestination{
|
|
public static void InitializeEncodingData(Instruction.InstructionData aData) {
|
|
aData.EncodingOptions.Add(new InstructionData.InstructionEncodingOption {
|
|
AllowedSizes = InstructionSizes.DWord,
|
|
OpCode = new byte[] { 0x58 },
|
|
NeedsModRMByte = false,
|
|
DestinationReg = Guid.Empty,
|
|
DestinationRegByte = 0
|
|
}); // pop to register
|
|
aData.EncodingOptions.Add(new InstructionData.InstructionEncodingOption {
|
|
AllowedSizes = InstructionSizes.DWord,
|
|
OpCode = new byte[]{0x8F},
|
|
NeedsModRMByte=true,
|
|
DestinationMemory=true,
|
|
DefaultSize = InstructionSize.DWord
|
|
}); // pop to memory
|
|
}
|
|
public override string ToString()
|
|
{
|
|
return base.mMnemonic + " dword " + this.GetDestinationAsString();
|
|
}
|
|
}
|
|
|
|
} |