为什么MSVC不支持内联汇编为AMD64和安腾的目标? [英] Why does MSVC not support inline assembly for AMD64 and Itanium targets?

查看:400
本文介绍了为什么MSVC不支持内联汇编为AMD64和安腾的目标?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

昨天我得知编译为AMD64和Itanium目标时,内联汇编(用__asm​​关键字)不是微软的Visual C ++的支持下

Yesterday I learned that inline assembly (with the __asm keyword) is not supported under Microsoft Visual C++ when compiling for AMD64 and Itanium targets.

这是否正确?如果是这样,没有人知道他们为什么不支持内嵌汇编这些目标?这似乎是一个相当大的功能,以刚落...

Is that correct? And if so, does anyone know why they would not support inline assembly for those targets? It seems like a rather big feature to just drop...

推荐答案

正确的,但仍然没有在的 VS 2010 Beta 1的。我的猜测是,内联汇编是太难以实施:微软实施的方式,它与周围的C $ C $ç集成,使数据可以流入和流出C $ C $的C,和适当的胶水code自动注入。为此,C编译器实际上需要了解汇编code;他们只是还没有实现,对于AMD64和Itanium。

Correct, it still isn't supported in VS 2010 Beta 1. My guess is that inline assembly is just too difficult to implement: the way Microsoft implemented it, it integrates with the surrounding C code so that data can flow in and out of the C code, and appropriate glue code is automatically injected. For that, the C compiler actually needs to understand the assembler code; they just haven't implemented that for AMD64 and Itanium.

这篇关于为什么MSVC不支持内联汇编为AMD64和安腾的目标?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆