dolphin1987dolphin.blog.chinaunix.net
dolphin1987
全部博文(1)
2010年(1)
mirnshi
scutan
dfl44886
分类: C/C++
2010-08-23 17:17:43
#include <stdio.h>unsigned long input = 0x12345678;unsigned long output = 0x10000000;int main(void){ asm volatile ("addl %1,%0 \n\t" :"=r"(output) :"r"(input)); printf("output:0x%x\n",output); return 0;}
#include "stdio.h"unsigned long input = 0x12345678;unsigned long output, zero; int main ( void ) { asm volatile ( "movl %1,%0\n\t" :"=r"(output) :"r"(input) ); printf("output:0x%x\t zero:0x%x\t\n",output,zero ); return 0;}
上一篇:没有了
下一篇:没有了
登录 注册