[英]System.Numerics.Vectors IsHardwareAccelerated returns false
I currently working on a project which switched from MathNet.Numerics library to the System.Numerics.Vectors library. 我目前正在研究一个项目,该项目从MathNet.Numerics库切换到System.Numerics.Vectors库。 I want to make use of the SIMD hardware support.
我想利用SIMD硬件支持。
The target framework of the application is .NET 4.6.1 so RyuJIT should be the default JIT compiler. 该应用程序的目标框架是.NET 4.6.1,因此RyuJIT应该是默认的JIT编译器。 UseRyuJIT is set to 1 in HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft.NETFramework .
UseRyuJIT在HKEY_LOCAL_MACHINE \\ SOFTWARE \\ Microsoft.NETFramework中设置为1。
But the System.Numerics.Vector.IsHardwareAccelerated
property still returns false. 但是
System.Numerics.Vector.IsHardwareAccelerated
属性仍然返回false。
The application runs in Release mode, Prefer 32-Bit is unchecked, Platform target is AnyCPU (though I also tried x64), enable native code debugging is checked and when i run it from Visual Studio and watch the Debug -> Windows -> Modules window I can see the clrjit.dll in the list. 该应用程序以发布模式运行,未选中“首选32位”,平台目标为AnyCPU(尽管我也尝试过x64),选中了启用本机代码调试,当我从Visual Studio中运行它时,请查看“调试”->“ Windows”->“模块”窗口中,我可以在列表中看到clrjit.dll 。 No protojit.dll (I think this was the CTP versions name) or compatjit.dll is active.
没有protojit.dll (我认为这是CTP版本名称)或compatjit.dll处于活动状态。
Furthermore there is no useLegacyJit enabled="1" set in the app config, no COMPLUS_useLegacyJit environment variable or a useLegacyJit flag in the regedit. 此外,在应用程序配置中没有设置useLegacyJit enabled =“ 1” ,在注册表编辑器中没有COMPLUS_useLegacyJit环境变量或useLegacyJit标志。
System information: 系统信息:
Windows 7 Professional Windows 7专业版
Visual Studio Professional 2013 Visual Studio专业版2013
System.Numerics.Vectors v4.1.2.0 System.Numerics.Vectors v4.1.2.0
Intel Core i7 3740QM 英特尔酷睿i7 3740QM
When you launch applications from Visual Studio the default setting, even for release builds, will disable jit optimizations, and that also disables SIMD code generation. 从Visual Studio启动应用程序时,即使是发行版,默认设置也会禁用jit优化,并且还会禁用SIMD代码生成。
You can change this within VS, by navigating to Tools | 您可以在VS中通过导航到“工具” |“更改” Options |
选项| Debugging |
调试| General and unchecking "Suppress JIT optimization on module load (Managed Only)".
常规并取消选中“禁止在模块负载上优化JIT(仅限托管)”。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.