view run/a/asm_mul_01_A.d @ 640:1fc8a80e4599

* added conditional jump tests * extended basic integer math tests
author thomask
date Tue, 23 Aug 2005 22:23:55 +0000
parents
children 000adc086356
line wrap: on
line source

// $HeadURL$
// $Date$
// $Author$

module dstress.run.a.asm_mul_01_A;

int main(){
	version(D_InlineAsm){
		ushort a;
		ubyte x = byte.max+2;
		
		asm{
			mov EAX, 0x12_34_56_78u;
			mov AL, 2;
			mul x;
			mov a, AX;
		}

		assert(a==(byte.max+2)*2);
		
		return 0;
	}else{
		pragma(msg, "no Inline asm support");
		static assert(0);
	}
}