“asm"、“__asm"和“__asm__"有什么区别? [英] What is the difference between 'asm', '__asm' and '__asm__'?
本文介绍了“asm"、“__asm"和“__asm__"有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
据我所知,__asm { ... };
和 __asm__("...");
之间的唯一区别是第一个使用mov eax, var
第二个使用 movl %0, %%eax
和 :"=r" (var)
最后.还有哪些不同之处?仅 asm
怎么样?
As far as I can tell, the only difference between __asm { ... };
and __asm__("...");
is that the first uses mov eax, var
and the second uses movl %0, %%eax
with :"=r" (var)
at the end. What other differences are there? And what about just asm
?
推荐答案
你使用哪一个取决于你的编译器.这不像 C 语言那样标准.
Which one you use depends on your compiler. This isn't standard like the C language.
这篇关于“asm"、“__asm"和“__asm__"有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文