Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Advantages of a 64 bit system

From a developer perspective i am trying to understand , what is the selling point of a 64-bit system ?

I understand that more registers are at your disposal , more memory can be allocated to a process , but i cannot understand what makes a developer's life easier. Any examples ?

From a performance perspective are there any gains seen if a program is run on a 32bit vs 64 bit ?

Cheers!

EDIT : Thank you for all your replies. I see some conversations shooting towards end user experience , important as it may be.. I am looking more at any architectural benefits that you can squeeze out.

From what i understand , it looks like the optimizations are a lot at the compiler-assembler chain rather than a functionality which a programmer can call on ?

like image 291
Ricko M Avatar asked Jan 29 '11 23:01

Ricko M


People also ask

What is the main advantage of 64-bit?

Computer Performance Using 64 bit operating system with 64 bit processer, the system can perform an increased number of calculations per second. As a result, it increases the processing power and makes a computer run faster. This is limited in case of 32 bit operating system.

What is the greatest advantage of using a 64-bit computer?

There are 3 most obvious advantages of 64-bit processors over their 32-bit counterparts: extended address space, capacity increase, and larger number of general-purpose registers.

What are two advantages of using a 64-bit installation of Windows?

Here are benefits\pros of using a 64-bit processor: Increased program performance and helps you to take advantage of a 64-bit operating system. Enhanced security feature. Windows 64-bit with a modern 64-bit processor allows you to take additional protection which is not available to 32-bit users.


4 Answers

When you have 64-bits of address space to play with, you can adopt certain designs that would be very hard with less of an address space. For example, a friend recently pointed out to me that address space for thread stacks can get to be a problem with thousands of threads on a 32-bit system. But on a 64-bit system, this is no longer even remotely close to being a problem. This is the main direct benefit to developers that can affect how you write programs. And this is true regardless of how much actual memory the machine has.

Most programs I have seen converted to 64-bit have seen performance improvements because of the extra registers available.

Having 64-bit addresses can offset this performance improvement in some programs. The extra space pointers take up mean they take more cache, which leaves less space in your cache for other things. Also they take up more memory bus bandwidth when being transferred to and from main memory.

There is at least one project out there that proposes to recompile most programs in Linux in a sort of mixed-mode in which all the extra registers are used, but only 32-bit pointers are used. I'm interested in how this pans out because it removes the one performance disadvantage of 64-bit programs.

There is also a small (but important) subset of programs and algorithms that can make use of 64-bit registers. For example, most of the SHA-3 candidates are designed to take advantage of the ability to manipulate 64-bits of data at a time when doing bitwise operations.

Lastly, since the data paths inside the CPU are now 64-bits wide, this can also mean there is more bandwidth inside the CPU for moving things around. But I would expect this to be a benefit on 64-bit CPUs running in 32-bit mode as well.

like image 134
Omnifarious Avatar answered Oct 14 '22 02:10

Omnifarious


When you run multiple processes e.g. debug session, compiler and other tools you will notice a big performance gain if you have lots of RAM in your system. I have 16GB RAM in my Win7 system and I will never go back to having less. Its a bit like when you start using dual monitors, one just isn't enough after that.

like image 28
AndersK Avatar answered Oct 14 '22 02:10

AndersK


As you said, more memory can be a big advantage. For 32bit systems you'll be limited to processes max 4GB (or even 2 or 3, depending how annoying your OS is).

64bits is double the amount of bytes per instruction, so you have more bandwith internally. eg: faster everything.

see also: http://lifehacker.com/5431284/the-lifehacker-guide-to-64+bit-vs-32+bit-operating-systems

like image 45
Harmen Avatar answered Oct 14 '22 02:10

Harmen


A few Mac OS X specific answers (general ones are covered in other replies):

1) In 32 bit OSX, address space is mapped 4/4 (i.e. kernel gets the full 2^32 AND each app does), which requires flushing the TLB twice on each syscall. In 64 bit there's plenty of room to map the kernel and the application into different address ranges.

2) Objective-C programs use the new ABI/runtime on 64 bit x86 machines. This gets you C++ compatible exceptions, non-fragile instance variables, and some speedups.

like image 20
Catfish_Man Avatar answered Oct 14 '22 00:10

Catfish_Man