Mercurial > projects > ldc
view tests/mini/asm3.d @ 981:855889b7b268
Update some testcases now that 64-bit immediates are working.
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Wed, 18 Feb 2009 23:18:34 +0100 |
parents | 03d7c4aac654 |
children | 4c524d80e6e1 |
line wrap: on
line source
module tangotests.asm3; extern(C) int printf(char*, ...); void main() { char* fmt = "Hello D World\n"; printf(fmt); version (LLVM_InlineAsm_X86) { asm { push fmt; call printf; pop EAX; } } else version(LLVM_InlineAsm_X86_64) { asm { movq RDI, fmt; xor AL, AL; call printf; } } }