What is the difference between 32 and 64-bit?
Just as the title says. I have been wondering this for a while. I know what the technical differences are between a 32-bit and 64-bit operating system, hardware, etc., but what does it actually do for the user? What benefit does the user get by having a 64-bit OS and compatible hardware?
The most obvious benefit is being able to use more than 4 GB of RAM without PAE. I believe that the 64-bit x86 CPUs also have more registers. Typically the RAM thing is the driving factor for 64-bit adoption though.
64-bit machines use 64-bit registers and memory locations. The memory locations can contain larger numbers, and the amount of available bytes will much bigger.
On a 32-bit machine, all addresses are stored in 32-bit, which means there are 2^32-1 bytes available for memory locations, which is 4 GB. On a 64-bit machine this is 2^64-1, which is extremely big. In other words: A user's application can use more memory than the 2GB limit per process, or 4GB of memory per computer.
Toolmaker
On a 32-bit machine, all addresses are stored in 32-bit, which means there are 2^32-1 bytes available for memory locations, which is 4 GB. On a 64-bit machine this is 2^64-1, which is extremely big. In other words: A user's application can use more memory than the 2GB limit per process, or 4GB of memory per computer.
Toolmaker
Didn't you know that 64-bit means it is better? I mean, don't you remember the Jaguar? [wink]
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter
Quote: Original post by Toolmaker
On a 64-bit machine this is 2^64-1, which is extremely big.
I bet we run out of address space in 30 years. :P
...only half kidding about that.
Globals are not evil. Singletons are evil.
The user sees no significant difference in the hardware itself.
The difference is within the software.
Their software can take advantage of more memory. It can take advantage of new instructions. It can take advantage of the various other processor changes.
It is similar to asking what a new version of SIMD instructions gives the user. The instructions give no direct benefit, but their new software can take advantage of it.
If the user is only going to use 32-bit software, and never use 64-bit software or 64-bit aware software on the box, then there is a strong case to stay with a 32-bit OS.
The difference is within the software.
Their software can take advantage of more memory. It can take advantage of new instructions. It can take advantage of the various other processor changes.
It is similar to asking what a new version of SIMD instructions gives the user. The instructions give no direct benefit, but their new software can take advantage of it.
If the user is only going to use 32-bit software, and never use 64-bit software or 64-bit aware software on the box, then there is a strong case to stay with a 32-bit OS.
For most people, 64 bits doesn't have any real advantages yet, only disadvantages. Pointers take twice as much storage, and context switches are four times as expensive. Thus, computionally intense threads competing over CPU cores (lots of context switches) may run noticeably slower than under 32 bits.
However, for some applications, 64 bits don't just offer some advantage, but they live in an entirely different world. In 64-bit mode, the CPU exposes not only registers of twice the original size, but also twice as many of them (among other things). Having twice as many registers may make no difference for some applications, but will make some algorithms run 10-15 times as fast, as they no longer have to store intermediates to main memory.
As for memory, most people (unless they're developers or gamers) don't use more than 512 MB anyway. Also, the 3.25 GB memory limit that you typically have in W32 is artificial. Unless your CPU is like 10 years old or you have PAE explicitely turned off, there is no real reason why there should be a limit at 4 GB (or rather 3.25 GB), other than being able to sell the server versions of Windows more expensive that way (those have no trouble using 16 GB of RAM).
Device drivers have no trouble with it either, even under non-"Server" versions (this is for example what the Superspeed ramdisk does).
Either way, 64 bit operating systems are the future, in maybe a year or two you might be getting trouble (well, let's not hope, but who knows!) finding 32 bit drivers for new hardware, as more and more manufacturers will move to 64 bits (which is the "mainstream" thing for Windows now too).
However, for some applications, 64 bits don't just offer some advantage, but they live in an entirely different world. In 64-bit mode, the CPU exposes not only registers of twice the original size, but also twice as many of them (among other things). Having twice as many registers may make no difference for some applications, but will make some algorithms run 10-15 times as fast, as they no longer have to store intermediates to main memory.
As for memory, most people (unless they're developers or gamers) don't use more than 512 MB anyway. Also, the 3.25 GB memory limit that you typically have in W32 is artificial. Unless your CPU is like 10 years old or you have PAE explicitely turned off, there is no real reason why there should be a limit at 4 GB (or rather 3.25 GB), other than being able to sell the server versions of Windows more expensive that way (those have no trouble using 16 GB of RAM).
Device drivers have no trouble with it either, even under non-"Server" versions (this is for example what the Superspeed ramdisk does).
Either way, 64 bit operating systems are the future, in maybe a year or two you might be getting trouble (well, let's not hope, but who knows!) finding 32 bit drivers for new hardware, as more and more manufacturers will move to 64 bits (which is the "mainstream" thing for Windows now too).
Also, the "Server" editions of Windows (since Windows Server 2008 R2) no longer come in 32-bit "flavour" and I presume that consumer versions of Windows will probably follow suit as well (maybe not in the next version, but definitely "soon").
But running 32-bit applications on 64-bit versions of Windows is still possible, and unless you actually need what 64-bit provides (bigger address space, mostly) there's not really any need to write 64-bit applications.
Whether your program will be faster compiled as 64-bit is a difficult thing to predict. I would say that in general the additional memory requirements (because all your pointers have doubled in size) results in a net loss of performance (particularly when your algorithms/data no longer fit in L1/L2 cache). Here's an interesting blog post on why Visual Studio doesn't have a 64-bit version.
But running 32-bit applications on 64-bit versions of Windows is still possible, and unless you actually need what 64-bit provides (bigger address space, mostly) there's not really any need to write 64-bit applications.
Whether your program will be faster compiled as 64-bit is a difficult thing to predict. I would say that in general the additional memory requirements (because all your pointers have doubled in size) results in a net loss of performance (particularly when your algorithms/data no longer fit in L1/L2 cache). Here's an interesting blog post on why Visual Studio doesn't have a 64-bit version.
Wow, thanks for all the background everyone! My concrete reason for asking was due the fact that I am wanting to upgrade to Windows 7 in a few months (after I get more word about how it is working out), and I am currently using a 32-bit Vista. I am not sure if there are different bit versions of Windows 7, but if there are, I was going to go for 64-bit. Thanks again!
There are 64-bit and 32-bit versions of Windows 7. I've been using the 64-bit version since it was released to MSDN and it's been great. There are advantages to using a 64-bit operating system (in particular PAE is only available on Server versions of Windows, not on workstation versions), even if all your applications are 32-bit, so I would definitely recommend it.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement