Friday 11 October 2013

Demystifying 32 bit vs 64 bit

For IT Engineers it seems that 32 bit vs 64 bit should be something everyone should be knowing like the back of their hand or maybe I should say like the bits 0 and 1. However, even though we have heard these terms numerous times many of us are not sure about the differences between 32 bit and 64 bit systems.

So lets attempt to put this across in simple terms for everyone to understand.

Lets be clear that this 32 bit vs 64 bit divide exists at 3 levels:

  1. We may say that at the innermost level we have 32 bit vs 64 bit processors
  2. At the next higher level we have the operating systems that may be 32 bit or 64 bit
  3. At the highest level we have applications that are 32 bit or 64 bit
Let us understand the distinction at each of the these levels

32 bit vs 64 bit Processors

Compared to the 32 bit processors, 64 bit processors are those that have datapath widths, integer size, and memory addresses widths of 64 bits. It will be interesting to know that 64-bit CPUs have existed in supercomputers since the 1970s (Cray-1, 1975) and in RISC-based workstations andservers since the early 1990s.

In the domain of personal computers, 64 bit processors were introduced around 2003 with the introduction of X86-64 and 64 bit power PC processor architectures.

It is commonly understood that with 32 bit processor architectures containing 32-bit address registers the processor can use a maximum of 2^32 addresses (or 4 GB of RAM, could be referenced).

With 64 bit processors, theoretically 2^64 or 16 exabytes of memory can be referenced.

32 bit vs 64 bit Operating Systems

64 bit operating systems quite simply are the ones that will make use of the 64 bit processors available to them along with the higher limit of the RAM.

The 64 bit operating systems are not only capable of using more RAM but also use it more efficiently. Additionally they are able to allocate more virtual memory to any process. For example a 32 bit Windows 7 is limited to using around 2GB virtual memory for a process but a 64 bit one can use up to 8 TB of virtual memory.

Thus one will see and feel an overall better and faster performance with a 64 bit OS on 64 bit hardware vs 32 bit OS on the 32 bit hardware

32 bit vs 64 bit Applications

Lastly lets look at 32 bit and 64 bit applications.
The applications' performance with respect to 32 bit or 64 bit is dependent only on their usage of the memory. For example if there is an application that may never use more than 2GB of memory then it will run equally well on both 32 bit and 64 bit systems.

However, applications that may want to use more memory (for example applications that open large files - e.g. a video editor) will hugely benefit from the fact that the OS and hence the application will be able to make use of higher amount of RAM and hence can run significantly faster with a 64 bit OS on 64 bit hardware.

The following two tables will help you get a quick grasp of compatibility of OS and applications on 32 bit and 64 bit architectures (credit: Techsupportalert)

Table 1 — What is compatible if I have a 32-bit CPU?
Processor (CPU)32-bit32-bit32-bit32-bit
Operating System (OS)32-bit32-bit64-bit64-bit
Application Program32-bit64-bit32-bit64-bit
YesNoNoNo
Table 2 — What is compatible if I have a 64-bit CPU?
Processor (CPU)64-bit64-bit64-bit64-bit
Operating System (OS)64-bit64-bit32-bit32-bit
Application Program64-bit32-bit32-bit64-bit
YesYesYesNo