在内核空间中使用 VC 内在函数
我的问题是,当头文件包含在 SDK(从 VC 10 安装)中并且我用来编译驱动程序的 WDK 不知道该文件时,如何在内核空间(在 Windows 上)中使用内在函数。当我 #include
一切正常,但是当我开始编译时,我得到
错误 C1083:无法打开包含文件:'intrin.h':没有这样的文件或目录
我尝试将相应的文件复制到 WDK 目录,但没有成功。我知道我可以开始编写内联汇编,但说实话,我想避免这样做,因为内在支持就在那里,我只是不知道如何访问它。
My question is how to use intrinsics in kernel space (on Windows), when the header file is contained with the SDK (as installed from VC 10) and the WDK which I'm using to compile the driver has no knowledge of this file. When I #include <intrin.h>
everything works fine but when I start to compile I get
error C1083: Cannot open include file: 'intrin.h': No such file or directory
I tried copying the appropriate files to the WDK directory but it didn't work out. I know I can start writing inline assembly but to be honest I want to refrain from this since the intrinsic support is there I just don't know how to access it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
WDK 目录中缺少一些较新的标头。只需将声明复制过来即可。
例如(因为 WDK 中缺少):
Some of the newer headers are missing in the WDK directories. Just copy the declaration over.
E.g. (because is missing from the WDK):