21

I'm trying to figure out why going to 64 bit processors is such a big deal in an iPhone. I understand that there will be twice as many registers so the processor can work with twice as much data which should increase performance.

However I don't see many phones going to more than 4GB of memory any time soon. It seems like overkill and it would negatively impact battery life.

Another problem that I see is that most variables now need twice as much memory. This will create problems in a mobile environment with small amounts of memory.

I believe that the folks at Apple are intelligent and they probably have great reasons for doing this, I'm just trying to understand them.

EDIT

Don't know much about GPU's but I was told that with 64 bit registers 2 pixels can be loaded into each register and operations can be performed on them individually. Is there a graphical advantage regarding 64 bit?

10
  • 2
    Just as a side note - more processing power means that programmers can afford to be lazier than before (less optimizations), a reason could be to encourage app developers.
    – Vlad Preda
    Sep 11, 2013 at 15:45
  • 3
    @Chris.Stover - Today there isn't an advantage. Of course tomorrow an iOS application will be able to use more memory once phones have more memory. In just 5 years phone memory capacity has increase by at least 200%. If the trend continues we could see 6GB-8GB phones in a very short amount of time. Apple also looks forward when they do something like this. It all comes down to the fact ARM is likely going to only license 64-bit designs going forward. It really comes down to the fact the phone now has more registers which really makes it faster. The 64-bit specification is not important today.
    – Ramhound
    Sep 11, 2013 at 15:46
  • 1
    It's not twice, it's orders of magnitude larger. 32-bit processors can only address 4 GB of RAM tops. 64-bit processors can address around 18 Exabytes which is 3 orders of magnitude higher.
    – user28988
    Sep 11, 2013 at 21:40
  • 7
    no more 640k memory limit
    – Reactgular
    Sep 13, 2013 at 12:49
  • 1
    It is suspected that the Nexus 5 will have 3 GB of RAM, and that's being launched next month. I don't think 4 GB+ is as far off as you might think.
    – Brendon
    Sep 15, 2013 at 21:08

10 Answers 10

25

It's mostly just throwing a big number out there because it impresses the masses. Bigger numbers are obviously superior so anything with a 64-bit processor is clearly better than something with a 32-bit processor. The new CPU is significantly better than its predecessor but, in Apple fashion, they're not going to try marketing based on tech specs - they're just going to tell you that the 64-bit A7 is newer & better than the 32-bit A-6. Looking at the tech specs, however, you see:

  • 28nm vs 32nm chipworks
  • Improved integrated graphics processor
  • ARM v8 architecture v. ARM v7 (adds SIMD functions; jumps from 13 to 31 general purpose registers)
  • On-die (ie - faster) main memory

Beyond that, there's the fact that they can start rolling out (backwards compatible) 64-bit hardware today, before we run up against the '4GB wall'. In a few years, when 64-bit becomes a necessity, all the hardware will support it & there won't be any need to handle legacy 32-bit architectures.

3
  • 1
    I can't actually find the source for the info in the wiki articles. Other sites are reporting dual core at 1.5GHz. One wiki page says the A7 is 1.7GHz octa-core. See the following: en.wikipedia.org/wiki/Apple_(system_on_chip) pdadb.net/index.php?m=pdacomparer&id1=4962&id2=4829 Sep 11, 2013 at 18:15
  • 2
    @Chris.Stover just goes to show that Apple doesn't sell hardware on tech specs - they just want to push "Newer & Better!" with the next generation rather than telling you why the new hardware is actually better. Sep 11, 2013 at 18:23
  • 2
    ARM v7 already supports 40bit address lines (1TB RAM), though apps on that 32-bit architecture can only address 4GB each. Arm v8 currently supports 32-bit apps so backwards compatibility isn't a problem.
    – gbjbaanb
    Sep 11, 2013 at 18:38
16

There is no "4GB wall" on ARMv7, as many ARMv7 cores support LPAE (Large Physical Address Extension), which is a concept symilar to PAE on x86, except LPAE uses 40-bit addressing. Meaning, that LPAE equipped ARMv7 can address up to 1TB of RAM.

It's also important to mention that upcoming ARMv8 cores, including A7, will not use 64-bit physical addressing. Most likely A7 will use either 40-bit or 44-bit physical addressing. Later giving access to at most 16TB RAM.

Of course either with LPAE on ARMv7 or in AArch32 mode on ARMv8, applications are still 32-bit, so the application itself can only access 4GB at a time. But I don't think it would be an issue on mobile devices any time soon.

You worry that apps will use more memory (64-bit pointers), but that won't be the case it the apps run in 32-bit mode (AArch32).

On the other hand ARMv8 provides other architectural improvements over ARMv7, which are not related to AArch64.

TL,DR: 64-bitness of A7 is marketing gimmick. Even on systems with more than 4GB RAM it provides no significant advantage over LPAE for 32-bit apps. And 64-bit apps aren't coming anytime soon.

Update: It's been confirmed by Qualcomm marketing executive (currently former executive, as he was demoted for these comments).

"I know there's a lot of noise because Apple did [64-bit] on their A7," said Anand Chandrasekher, senior vice president and chief marketing officer at Qualcomm, in an interview. "I think they are doing a marketing gimmick. There's zero benefit a consumer gets from that."

A benefit of 64-bit is more memory addressability, but that is not relevant in today's smartphones or tablets, Chandrasekher said. The iPhone 5s has only 1GB of DRAM.

"Predominantly... you need it for memory addressability beyond 4GB. That's it. You don't really need it for performance, and the kinds of applications that 64-bit get used in mostly are large, server-class applications," said Chandrasekher, who previously ran Intel's mobile platforms group. (source)

9

Focusing solely on A7 being ARMv8 there is one obvious gain. ARM is rebooting their instruction set and architecture.

Being backwards compability with ARMv7, next version also claims

  • New instruction set (A64)
  • Revised exception handling for exceptions in AArch64 state
  • Fewer banked registers and modes

So ARMv8 challenges ARMv7 on architectural differences, providing a cleaner interface for system developers which would probably remove legacy features leading to a better platform. Which means you should expect a better performance/energy instead of negative impact on battery.

See more on ARM Architecture Preview.

1
4

The biggest advantage over 32 bit for 64 bit processors is the movement of memory, and not the size of memory. While it's true that 32 bit can impose a 4GB limit on direct access. There are many hardware/software solutions to get around that limit.

64 bit processors can simply read/write more data in a single processor operation. It allows the assembly code to perform operations on 8 byte blocks. This can have a great performance advantage over 32 bit processors. Floating point calculations are faster on 64 then 32, and when the CPU uses dual registers it can operate on 128 bit data blocks.

64 bit processors also have wider bandwidths to physical memory. If you have a camera that records 1080p and want to edit that video. Performing an operation on a 1GB video file will simply be faster on 64-bit.

All the above is true even if the Ghz of the processor remains the same.

If 64-bit is so good, then why not 128 bit?

The more bits you add to the pipeline of a CPU the more data that the CPU has to move. The CPU can not narrow that bandwidth down to 16 or 32. So this creates a problem for software developers. Most software (your calendar, notes, etc..) don't depend upon a lot of data, and as a result 128 bits would involve a lot of wasted bandwidth. This can start to hinder performance and battery life. So the CPU manufactures have to find a balance between bandwidth and software requirements.

I'm amazed that Apple released a new 64 processor so soon in the life of mobile computing. I think their real motivation for this is 3D graphics. With a 64 bit processor the phone can move more data to the GPU quickly. This will allow for fast 3D games and more impressive graphics. You'll really start to see the advantages of 64-bit in real-time 3D because that process depends greatly on data.

2
  • 4
    Recent/modern CPU architectures are much complicated than you describe here. CPUs move data from memory in units called cache lines over memory buses which might have 16-bit 32-bit or probably 64-bit. That doesn't necessary matches CPU arch's native word size. You are right that big problem is moving data but that problem belongs to some other hardware/architectural domain. FP is done on FPU which are actually quite fast and can work with single or double precision sizes. Same for video decoding or 3D actually, they have all their own dedicated hardwares which aren't necessarily 64-bit.
    – auselen
    Sep 13, 2013 at 17:56
  • 4
    There is a terrific document called what every programmer should know about memory available free for the curious developer akkadia.org/drepper/cpumemory.pdf
    – auselen
    Sep 13, 2013 at 18:10
2

It makes things easier when handling large numbers. Large numbers are extremely important in cryptography (after PRISM having a secure mobile phone has become very important) and scientific applications.

1

While you might not run into issues now if you stick to 32 bit, there certainly will be issues in the near future. The lesson learned from the desktop-world is that a transition will be a lengthy and painfull process. So you should start with it sooner rather then later.

It was even surprising to me that smartphones weren't 64 bit bit from the get go.

1
  • I tested this out by converting my current app to 32 bit. I had a number of warnings but no errors. Luckily apple had a suggested fix for every warning so I just clicked each warning and hit enter to accept the fix. Took about 5 minutes and I was up and running in 64 bit. No headache no problems... so far Sep 13, 2013 at 18:30
0

I don't think there are a lot of technical benefits. First I think it makes more sense when you consider the iPad (it has a bigger battery so it can support more ram, higher energy consumption by the processor, etc.). Second look at the other announcements going on right now. AMD just announced it is going to be shipping 64bit ARM processors in 2014. This is basically Apple keeping market leadership in the face of what is coming to high end Android and Win8 tablets.

0

In the short run pretty much nothing. It's actually a step back in a few ways. There are three main advantages that I know of.

  1. 64bit is a lot better with larger numbers, which is a boon to crypto. Which may be an interesting combine with the finger print scanner on the phone.
  2. Again in the same vein, the improvements with 64bit and large numbers help with physics rendering. Which is handy considering the amount of physics used in the UI of iOS7. This also benefits game developers as well especially on something with larger screen real estate like the iPad.
  3. It's also adds some degree of future proofing current phones using this.
0

Benchmarks.

For some implementations capable of both 32 vs. 64 bit architectural modes of with x86, MIPS and ARM ISAs, the 64 bit mode benchmarked faster on certain important applications. One key reason is that the 64 bit ISAs are newer and the ISA architects thus knew more about the application statistics and how to optimize for that set of application behaviors when defining the ISA. And a new processor ISA needs to be future-proof against application memory needs that are growing at Moore's law pace, and which have already grown over a million-fold in the mobile device area.

Thus the new arm64 ISA likely benchmarks faster on any performance constrained code you might develop (it has on my code), as well as allowing dumb C pointers to address the vast virtual address spaces likely to become common a decade or more hence (which is much less time than the original 32 bit ARM ISA has already existed).

Performance on your particular set of applications (measure to confirm) is a great reason to prefer arm64.

-4

64-bit allows a great deal more code sharing with the desktop builds of OSX (which are all 64-bit)

2
  • But currently all ios app must maintain 32-bit compatibility so any 64-bit only code must be convert to 32-bit anyway.
    – Bryan Chen
    Sep 12, 2013 at 1:21
  • 1
    But they are completely different architecture (x86-64 vs. armv8) anyway. Zero gain from that (sanely written program in C/C++/ObjC will work on any number of bits even if it's not a requirement).
    – Jan Hudec
    Sep 13, 2013 at 9:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.