Apple's macroscalar architecture: what it is & what it means

Apple's macroscalar architecture: what it is & what it means

Summary: What the heck is Apple's macroscalar processor? And why should we care?


What in heck is Apple's macroscalar processor? And why should we care?

Apple got a new patent on something called a macroscalar processor this month. You may have seen a write-up on it that quoted the application and stopped there. Because no one knows what it is and why you would want one. But I know.

Macroscalar Macroscalar is NOT a term of art in computer science - although a quick Bing search will find that it is occasionally used in other disciplines by academics eager not to be understood. Let's break it down.

Macro means - in a word of 1 syllable - big. Macroeconomics explains the big gears of the economy. Macro lenses make little things big by getting close to them. Office macros make big, complex actions into 1 command.

Scalar means a single value, as opposed to a vector. A vector processor takes a vector of values, say

10 14 666 22 84 53 45 25 14 47 91

and with 1 instruction performs the same operation on all of them, such as multiplying by a single scalar value or another vector.

When you have masses of data to massage - such as in imaging - vector processors speed things up. Which is why the companies that built vector processors for a living got killed by Intel and GPUs.

Scalar OTOH, means a single value. So what the heck is a BIG single value processor?

Parallel processing loops As the Background of the Invention section in the patent explains, rising clock frequencies aren't translating into higher performance because most consumer software isn't optimized to use longer pipelines.

While consumers purchase newer and faster processors with deeper pipelines, the vast majority of software available is still targeted for processors with shorter pipelines. As a result of this the consumer may not realize the full processing potential of a new processor for one to two years after its release, and only after making additional investments to obtain updated software. . . . (I)t is questionable how efficiently deeper pipelines will actually be utilized.

This is important because as CPUs hit Moore's Wall, more parallelism is the chief way to get more performance - and deeper pipelines are a chief way to achieve instruction-level parallelism.

What is a pipeline? Skip this if you already know. As defined in Wikipedia an instruction pipeline is a technique used in the design of computers and other digital electronic devices to increase their instruction throughput (the number of instructions that can be executed in a unit of time).

Here's a graphic example from Wikipedia:

Since a good portion of a typical program's time is spent in loops, optimizing loops for parallel execution is a popular form of speed up. Loop unrolling and auto-vectorization are 2 common techniques, but they don't work with data-dependent loops whose length depends on their results rather than a fixed number of iterations.

The invention The macroscalar processor addresses this problem in a new way: at compile-time it generates contingent secondary instructions so when a data-dependent loop completes the next set of instructions are ready to execute. In effect, it loads another pipeline for, say, completing a loop, so the pipeline remains full whether the loop continues or completes. It can also load a set of sequential instructions that run within or between loops, speeding execution as well.

The macro piece is the large number of program registers required so that all or most possible instruction paths are already loaded into CPU registers for fast execution. Instead of maintaining 1 pipeline, the architecture effectively maintains parallel pipelines, loading them and then switching between them to maximize loop performance.

Much of the patent is focused on compiler coding needed to take advantage of the macroscalar architecture. Essentially the compiler needs to analyze the work flow and understand where run-time decisions will be made so the processor can know when it needs an alternate pipeline.

The Storage Bits take Apple is, among other things, a fabless semiconductor company. They design, but do not build, their own processors, such as the dual-core A5 in the iPad 2.

The macroscalar architecture, well implemented, offers higher performance for a given clock-speed and lower energy consumption. Both are valuable in mobile devices.

Since Apple provides its own compilers as well as designing CPUs, it is uniquely positioned to offer a complete macroscalar solution to its large band of iOS developers, further widening the price/performance gap between it and the iPad wannabes.

Is it a breakthrough? It could be if the efficiencies it promises can be realized in practice. We'll have to see just how good Apple's compiler engineers are.

Comments welcome, of course. Macroscalar is another way to throw transistors at the problem of speeding up computers. I like it.

Topics: Processors, Apple, Hardware

Kick off your day with ZDNet's daily email newsletter. It's the freshest tech news and opinion, served hot. Get it.


Log in or register to join the discussion
  • Since we learn about this via patent information, this usually means that

    ... this technology is either already implemented in Apple's A5/XCode SDK (which includes regimes for iPad/iPhone/iPod touch), or it will not be done in the near future at all since it might be really good idea theoretically, but not really good in practice because of some not that obvious nuances that break the beauty of the approach.<br><br>(It is utterly rare that Apple's patents information precedes soon to be implemented technology. Basically, I am yet to see that variant.)
    • How fun!

      You seem to be the target of "Mr/Ms Flag Them"
  • RE: Apple's macroscalar architecture: what it is & what it means

    Given your description, it's hard to believe this wasn't thought of and implemented around 1994.
    • RE: Apple's macroscalar architecture: what it is & what it means

      @rynning It may have been, but the economics favored more profitable uses of transistors, such as branch prediction. This is feasible now because we have billion transistor chips.
      Robin Harris
      • Thank you for writing on tech

        A breath of fresh air. Other zdnet bloggers should take note, and flag away "writing" the "omg, read my pap, it's important for page hits" froth and bubble that is way too common on zdnet these days.
      • Question

        So, how could you take advantage of this as a coder/designer? Do you have anything on that?
      • Article title is more than just a little

        @Robin Harris .. misleading.<br><br><i>"...Apple got a new patent on something called a macroscalar processor this month."</i><br><br>Is the blog about patents or Storage Bits / Media? I mean, that's the subject matter you chose to open with.<br><br>So, your first mention is of a 'patent' .. not an actual technology. What's the significance of a patent to 'The Storage Bits take'?? While you're at it, can you eloborate on how 'patents' relate to CPU clock timings and their subsequent affect on I/O scheduling (for example).<br><br><i>"...Apple is, among other things, a fabless semiconductor company. They design, but do not build, their own processors,"</i><br><br>Which begs the obvious question: since when did Apple magically become "great designers of processors"?? <br><br>Then you throw in this completely contradictory doozey ..<br><br><i>"...Since Apple provides its own ... as well as designing CPUs..."</i><br><br>Are we now to believe that Apple have been designing CPU's and that Intel (and now AMD) actually haven't been providing processors to Apple?<br><br>I'm having difficulty finding much media on Apple supplanting Intel and AMD in the processor space .. is there some insider info' you're holding out on us with?<br><br>Now look, the macro-scalar concepts involved sound great ... i simply don't get why you felt the need to even mention the word 'patent' in a blog that supposedly revolves around Storage Media and related processing. <br><br>That aside, there are inconsistencies and misleading material in your write-up that just plain don't add up.<br><br>So .. please, do elaborate.
  • RE: Apple's macroscalar architecture: what it is & what it means

    Thanks for sharing the knowledge. It was a pleasure to read and learn from your blog
  • This post reminds me of Byte Mag.

    When real articles were written about technology rather than just reviews. Good stuff.
  • Updated Information Links:

    A *much* better explanation can be found in Apple's patent filings.
    • RE: Apple's macroscalar architecture: what it is & what it means


      Thanks for this. I tried hard to understand above but i really am having a hard time understanding it. lol. <a style="text-decoration: none; color: black;" href="pacquiao vs marquez tickets">pacquiao vs marquez tickets</a>
  • RE: Apple's macroscalar architecture: what it is & what it means

    I really enjoyed reading this post !!!have bookmarked <a href="">w</a><a href="">e</a><a href="">b</a><a href="">s</a> will come back to read more.