DIV() public method

DIV mem8
public DIV ( ByteMemory target ) : void
target ByteMemory
return void
Esempio n. 1
0
	public void DIV_rmreg32 ()
	{
		// DIV EBP
		// DIV (R32.EBP)
		MemoryStream memoryStream = new MemoryStream ();
		Assembly asm = new Assembly ();
		asm.DIV (R32.EBP);
		asm.Encode (memoryStream);
		byte [] target = new byte [] { 0xf7, 0xf5 };
		Assert.IsTrue (CompareData (memoryStream, target), "'DIV EBP' failed.");
	}
Esempio n. 2
0
	public void DIV_rmreg16 ()
	{
		// DIV SI
		// DIV (R16.SI)
		MemoryStream memoryStream = new MemoryStream ();
		Assembly asm = new Assembly ();
		asm.DIV (R16.SI);
		asm.Encode (memoryStream);
		byte [] target = new byte [] { 0x66, 0xf7, 0xf6 };
		Assert.IsTrue (CompareData (memoryStream, target), "'DIV SI' failed.");
	}
Esempio n. 3
0
	public void DIV_rmreg8 ()
	{
		// DIV DL
		// DIV (R8.DL)
		MemoryStream memoryStream = new MemoryStream ();
		Assembly asm = new Assembly ();
		asm.DIV (R8.DL);
		asm.Encode (memoryStream);
		byte [] target = new byte [] { 0xf6, 0xf2 };
		Assert.IsTrue (CompareData (memoryStream, target), "'DIV DL' failed.");
	}
Esempio n. 4
0
	public void DIV_mem32 ()
	{
		// DIV DWord [ESP]
		// DIV (new DWordMemory(null, R32.ESP, null, 0))
		MemoryStream memoryStream = new MemoryStream ();
		Assembly asm = new Assembly ();
		asm.DIV (new DWordMemory (null, R32.ESP, null, 0));
		asm.Encode (memoryStream);
		byte [] target = new byte [] { 0xf7, 0x34, 0x24 };
		Assert.IsTrue (CompareData (memoryStream, target), "'DIV DWord [ESP]' failed.");
	}
Esempio n. 5
0
	public void DIV_mem16 ()
	{
		// DIV Word [0x12345678]
		// DIV (new WordMemory(null, null, null, 0, 0x12345678))
		MemoryStream memoryStream = new MemoryStream ();
		Assembly asm = new Assembly ();
		asm.DIV (new WordMemory (null, null, null, 0, 0x12345678));
		asm.Encode (memoryStream);
		byte [] target = new byte [] { 0x66, 0xf7, 0x35, 0x78, 0x56, 0x34, 0x12 };
		Assert.IsTrue (CompareData (memoryStream, target), "'DIV Word [0x12345678]' failed.");
	}
Esempio n. 6
0
	public void DIV_mem8 ()
	{
		// DIV Byte [DS:0x12345678]
		// DIV (new ByteMemory(Seg.DS, null, null, 0, 0x12345678))
		MemoryStream memoryStream = new MemoryStream ();
		Assembly asm = new Assembly ();
		asm.DIV (new ByteMemory (Seg.DS, null, null, 0, 0x12345678));
		asm.Encode (memoryStream);
		byte [] target = new byte [] { 0x3e, 0xf6, 0x35, 0x78, 0x56, 0x34, 0x12 };
		Assert.IsTrue (CompareData (memoryStream, target), "'DIV Byte [DS:0x12345678]' failed.");
	}