9/12/2014

Why ARM’s 64-bit architecture is good for developers and good for users

[​IMG]The history of 64-bit computing is quite varied and interesting. Companies like Cray started using 64-bit registers in their systems in the mid-1970s, however pure 64-bit computing didn’t really come about until the 1990s. First came the R4000 from MIPS, and then the Alpha processor from DEC. By the mid-1990s Intel and Sun both had 64-bit designs, however the real turning point for consumers came in 2003 when AMD released a 64-bit PC processor that was compatible with Intel’s 32-bit x86 processors.


ARM saw the need for energy-efficient 64-bit processors and started working new designs long before announcing its new ARMv8-A architecture.
Fast forward 10 years, PC sales are in decline and most smartphones and tablets have multi-core processors running at speeds of between 1 and 2GHz. However these devices use a 32-bit architecture and not a 64-bit architecture like modern PCs and servers. Until now that was perfectly acceptable. Smartphones weren’t meant to compete with PCs in terms of performance and the processors needed to be energy efficient to maximize battery life.

However as devices have developed and new technologies like voice recognition, realistic 3D gaming and high resolution displays, have become the norm, the humble 32-bit processor is slowly being pushed towards its limits.

ARM saw the need for energy-efficient 64-bit processors and started working new designs long before announcing its new ARMv8-A architecture, the first ARM architecture to include a 64-bit instruction set. ARM also learnt from the mistakes and successes of other chip designers who moved to 64-bits. ARM’s new 64-bit architecture is fully compatible with its 32-bit architecture. This means that if the processor is running on a 64-bit enabled operating system, the processor is able to run unmodified ARMv7 32-bit binaries. For Android this means that once the kernel has been ported to 64-bits (and it has already thanks to Linaro) then the rest of the OS, from core libraries to apps and games, can be either 32-bit or 64-bit.

[​IMG]

Last year Apple shook the mobile world when it announced that the iPhone 5S would use the new 64-bit Apple A7 processor. The A7 includes an Apple designed ARMv8 dual-core CPU, called Cyclone. It uses two 64KB L1 caches (one for each core), a 1MB L2 cache shared by both CPU cores, and a 4 MB L3 cache for the entire SoC. Apple holds an ARM architecture license which means it can design its own processors from scratch, but with the provision that these processors must be ARM compatible. ARM has a series of test suites which is runs against such processors to ensure compatibility.

Over the next few months we are going to see 64-bit ARM based processors coming from companies like SamsungQualcomm and MediaTek. When coupled with the 64-bit work being done on Android, it is clear that we will see 64-bit devices running on a 64-bit version of Android before long. But what do 64-bit processors mean to developers and end-users?

Benefits of ARM’s 64-bits


At the heart of every CPU is a set of registers. These are internal storage slots which store numbers and addresses. If you want to add 5 to a number then one way to do it would be to tell the CPU to add 5 to the contents of a register, say register 7 (R7) and place the result in R8. The same applies to other operations like subtract, multiply, shift and so on.


The ARMv8 architecture has 31 general registers, each 64-bits wide.
When the processor is performing complex operations these slots are used and re-used constantly. If all the registers are currently occupied then the only way to proceed is to store one of the registers in memory, use the register for the next task, and then load the previous value back in from memory. In human terms this can all happen at lightning speeds, but for a processor this is actually a time consuming sequence of events and it is not very efficient.

The 32-bit ARMv7 architecture had 15 general purpose registers, each 32-bits wide. The ARMv8 architecture has 31 general registers, each 64-bits wide. This means that optimized code should be able to use the internal registers more often than memory, and that these registers can hold bigger numbers and addresses. The result is that ARM’s 64-bit processors can do things quicker.

In terms of energy efficiency, the use of 64-bit registers doesn’t increase the power usage. In some cases the fact that a 64-bit core can perform certain operations quicker means that it will be more energy efficient than a 32-bit core, simply because it gets the job done faster and can then power down.

[​IMG]



The other aspect of 64-bit processors is the addressing. In the world of PCs and servers the 32-bit barrier was primarily talked about in terms of accessible memory. If you wanted more than 4GB of RAM then you need a 64-bit processor. This isn’t strictly true with ARM processors as some ARMv7 processors can access more than 4GB of memory using its Large Physical Address Extensions (LPAE). With LPAE a Cortex-A15 processor can address 1024GB of memory. Since 64-bits is approximately the number of atoms in a small galaxy, there aren’t going to be any smartphones that need full 64-bit addressing any day soon! Since catering for address space that is never going to be used is futile, the ARMv8 architecture has 48 bit addressing, that is 256 terabytes!

OK, I don’t expect any games that needs terabytes of memory in the immediate future, but back down at the other end of the scale such address capabilities are very important. Modern 3D games often come with huge amounts of resources (assets), these assets can be more easily memory mapped when there is greater than 4GB of address space. This will speed up games and allow for direct access to the games media resources.

[​IMG]

More than just smartphones and tablets


The benefits of 64-bit computing on ARM aren’t limited to just smartphones and tablets. ARM’s eco system is vast and its processors are found in many different types of devices. One area where ARM processors haven’t made much in roads is in the server market. As the information age continues to advance the amount of energy used to power all those data centers is increasing rapidly. Any reduction in power usage saves money and saves on natural resources. Putting 64-bit ARM chips in servers has several other benefits than just the reduced power usage. These servers are passively cooled which means that you can cram them together without the worry of over heating. It also means that less money is spend on cooling.

[​IMG]

In terms of server software, operating systems like Linux are already 64-bit and there is support for ARMv8 already in the mainline kernel. This means that servers running 64-bit Linux on ARM won’t be hard to build, or sell!

Chromebooks are another area where ARMv8 could become dominant. There are ARMv7 Chromebooks already and I am sure it won’t be long before we see ARMv8 ones.

Wrap up


The age of 64-bit mobile computing is upon us, mainly thanks to ARM. These new processors are faster and open up mobile platforms to a whole range of new possibilities, all while staying true to ARM’s low-power heritage.

The migration path from 32-bit to 64-bit is well trodden and there shouldn’t be any surprises for developers going from 32-bit to 64-bit on ARM, regardless of the OS.

ARM’s partners will be producing Cortex-A53 and Cortex-A57 processors over the coming months, some will work in the more standard dual-core and quad-core configurations, while some will work together in big.LITTLE setups. And one thing is sure, this is an exciting time for ARM and for all of us who use the processors based on their designs.
Lien:meilleur mobile 2014

No comments:

Post a Comment

Download Movies on iPhone for Free? Learn the Best Way

1. Top 5 Free Websites to Download Movies for iPhone Below we have detailed some of the best and legal websites that allow you to download m...