托管在.NET4应用.NET2组件有更好的表现在86比值为anycpu模式?值为、组件、模式、anycpu

2023-09-03 16:47:00 作者:-<-剑荡パ荒ゞ

我有一个.NET4 WinForms应用程序引用第三方.NET2组件,包含图形复杂的可视控件。我注意到一个巨大改善应用程序的视觉表现,当我不小心打开它值为anycpu x86的编译模式。我的发展钻机是一个64位的Windows 7的改进,是通过至少两个因素控制按钮时呈现他们的图形元素。

I have a .Net4 WinForms app that references 3rd party .Net2 assemblies, which contain graphics-heavy visual controls. I've noticed a huge improvement in app's visual performance when I accidentally switched it from AnyCpu to x86 compilation mode. My development rig is a x64 Windows 7. The improvement is by a factor of at least two when controls are rendering their graphical elements.

这是一个众所周知的事实还是我做错了什么?

Is this a known fact or am I doing something wrong?

推荐答案

请参阅一下这两篇文章:

See these two articles about it:

值为anycpu EXE文件通常是更多的麻烦比他们的价值

Visual Studio中:为什么没有64位版本? (还)

也看到这个职位约64位code:的我应该选择以充分利用64位的?,它明确规定,例如Paint.NET工作下的64位模式更好,因为开发人员优化了code为64位

See also this post about 64-bit code: Should I choose to take advantage of 64-bit?, it clearly states that for example Paint.NET works better under in 64-bit mode, because the developer optimized the code for 64-bit.

所以,我不认为您正在做​​的事情错了,但也许你正在使用的64位进程中运行时,可以特别提高第三方.NET程序集。

So, I don't think you are doing something wrong, but maybe the 3rd party .NET assemblies you're using could be improved specifically when running in a 64-bit process.