有没有任何真正的点编译Windows应用程序作为64位? [英] Is there any real point compiling a Windows application as 64-bit?

查看:88
本文介绍了有没有任何真正的点编译Windows应用程序作为64位?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我会自信地说,我们写的99%的应用程序不需要占用超过2Gb的内存。当然,操作系统运行64位来处理更多的RAM有很多明显的好处,但是有什么特别的原因,一个典型的应用程序将编译64位?

I'd confidently say 99% of applications we write don't need to address more than 2Gb of memory. Of course, there's a lot of obvious benefit to the OS running 64-bit to address more RAM, but is there any particular reason a typical application would be compiled 64bit?

推荐答案

64位可能会出现性能改进。一个很好的例子是函数调用中的一些参数通过寄存器传递(更少的东西推栈)。

There are performance improvements that might see with 64-bit. A good example is that some parameters in function calls are passed via registers (less things to push on the stack).

编辑
当我研究一些运行我们的产品与64位构建与32位构建的差异时,我查找了一些我的旧笔记。我在四核64位机器上运行测试。所以有一个问题,比较苹果和桔子,因为32位在仿真模式下运行明显。但是,似乎很多事情我读的这样,例如,一贯说,速度命中为WOW64并不重要。但即使该语句不是真的,你的应用程序几乎肯定会在64位操作系统上运行。因此,64位机器上的32位构建与64位的比较具有价值。

Edit I looked up some of my old notes from when I was studying some of the differences of running our product with a 64-bit build versus a 32-bit build. I ran the tests on a quad core 64-bit machine. So there is the question of comparing apples to oranges since the 32-bit was running under the emulation mode obviously. However, it seems that many things I read such as this, for example, consistently say that the speed hit for WOW64 is not significant. But even if that statement is not true, your application will almost certainly be run on a 64-bit OS. Thus a comparison of a 32-bit build versus 64-bit on a 64-bit machine has value.

在我执行的测试(肯定不全面)中,没有找到任何32位构建更快的情况。然而,我运行的许多SQL密集型操作(高CPU和高I / O)在使用64位构建时运行速度快20%至50%。这些测试涉及一些相当丑陋的SQL语句以及一些具有高并发性的TPCC测试。当然,很大程度上取决于编译器开关相当多,所以你需要做自己的测试。

In the testing I performed (certainly not comprehensive), I did not find any cases where the 32-bit build was faster. However many of the SQL intensive operations I ran (high CPU and high I/O) were 20% to 50% faster when running with the 64-bit build. These tests involved some fairly "ugly" SQL statements and also some TPCC tests with high concurrency. Of course, a lot depends on compiler switches quite a bit, so you need to do your own testing.

这篇关于有没有任何真正的点编译Windows应用程序作为64位?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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