04 October 2011

Writing Faster Programs about to be Harder and Harder

The computer-buying public have known for a year or two that individual central processing units or cores have ceased increasing in speed. The faster computers on the shelves need multiple cores. The same is becoming true for smartphones and tablets that now need multiple cores to be faster. But heed the warning from Steve Blackburn in his post on ‘Performance anxiety: the end of software’s free ride’. Writing software that runs faster from here on in is going to be very difficult indeed.

As Steve points out we have known how hard it is to write software to keep our multiple cores executing at the same time, ie parallel processing. He cites the simple example:

just as two cars are unlikely to get you to work faster than one, the addition of another core is often unhelpful in completing a computing problem more quickly

In the last 30 years of my computing experience the advances in writing parallel programs have been slight. So this is the first hard problem.

We used to think it was easier to make all the cores the same but it is now becoming clear we need a hierarchy of cores with varying power to control them efficiently – ‘ many designers now believe that we need a more complex combination of simple and powerful cores on each chip’. so ‘ heterogeneity takes us even further from the world of transparent performance improvements’.

Steve then reveals the problem of giving enough power to lots of cores on one chip. There is an obvious physical limit.

In practice, power densities on chip have become so high that we can no longer fully power an entire chip lest we melt the silicon. This radically changes the economics of microarchitecture.

Thus software developers must now optimise for energy consumption, not performance – a completely new approach will be needed. New optimisation algorithms will be needed.

The hard problem of parallelism still lies unsolved after decades. We computer scientists are going to have to do a lot better with the heterogeneity and energy optimisation hard problems if smartphone/tablet/laptop/desktop performance is not to stagnate. A dim prospect indeed unless some new lateral thinking can come to the rescue.

No comments:

Post a Comment