Do 32 bit programs run relatively slower on 64 bit OS against when they are natively run in 32 bit OS

非 Y 不嫁゛ 提交于 2020-01-02 05:34:14

问题


I was reading about WOW 64 here http://en.wikipedia.org/wiki/WOW64

and learnt that its a layer in 64 bit Windows OS to run 32 bit programs.

So can I assume that 32 bit programs run relatively slower on 64 bit OS against when they are natively run in 32 bit OS.

I can see the advantages of memory access of over 4 GB in 64 bit OS. But does this advantage necessarily offset the small overhead added by layer of WOW64 ? Are there any other advantages of 64 bit which offset this.


回答1:


The main advantage of a 64-bit system is that it allows applications in 64-bit mode, which, in turn, is primarily useful if you need to access more than 4GB memory. If you have that requirement, using a 64-bit system is your only choice. Your application would be using 64-bit code, so WOW64 would not be used, and thus not cause problems.

If you don't really have the requirement to use more than 4GB of memory in a single process, it becomes debatable whether 64-bit Windows is really an improvement. You might need 64-bit Windows if you want to use more than 4GB of main memory at all (although you can also use PAE for that, which has its own disadvantages). Still, on a 64-bit system, you can run 64-bit applications. With AMD64 processors, 64-bit mode might be faster than native 32-bit mode, because the processor has more registers. Whether this slight gain outweighs the slight loss wrt. WOW64 depends on your application mix.

Personally, I think many people install 64-bit Windows because they don't fully understand the consequences of doing so, but feel they are on the safe side (which they may not, due to the lack of drivers).



来源:https://stackoverflow.com/questions/4478162/do-32-bit-programs-run-relatively-slower-on-64-bit-os-against-when-they-are-nati

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!