tags:

views:

57

answers:

2

I know that the additional consideratiosn when compiling for x64 is that some data types, like ints, can hold larger values. Are there any concerns?

VS2010, released a few days ago, can support compiling for x64 and x32, just like VS2008. The app is x32/86 only. I keep thinking that the app needs to be 64 bit however. What am I missing? Obviously this is not the case.

Thanks

A: 

Reasons to build for x86-64:

  • your app needs > 4 GB address space

  • your app is performance-critical and could benefit from ~30% performance improvement due to increased size and number of registers

If neither of the above applies then there is no compelling reason to make an app 64-bit.

Paul R
@Paul R - Just curious, where did you get that number (30%) from?
PhiS
@PhiS: empirical evidence, based on compute-intensive code (mostly image processing type stuff) that I've tested on x86 and x86-64 (Intel only though - may not apply to AMD).
Paul R
And some apps will be slower on x64, let me pull a number from my ass, say around ~30% slower. This is mostly due to the cache being relatively smaller (because pointers now require double the memory and cache space.) So unless you do heavy 64bit number crunching, or need the address space, it's usually not worth it.
Eloff
@Eloff: I'm basing my 30% claim on benchmark data that I've collected for various bits of code that I have developed. True, these are mostly compute-intensive "number crunching" routines, but the 30% performance improvement with x86-64 seems to be remarkably consistent.
Paul R
A: 

Regarding VS2010 (IDE & plugins) not being a 64 bit app, i believe there are 2 main reasons -

  1. If the app is 64 bit, then pointers and ints would consume twice more memory which would be worse for most folks.

  2. Parts of Visual Studio are already ported to .NET. It would be simpler to finish porting rest of it to .NET rather than port C/C++ code to x64.

http://blogs.msdn.com/ricom/archive/2009/06/10/visual-studio-why-is-there-no-64-bit-version.aspx

andy318