Sunday, June 7, 2009

Technical Challenge of Multiple CPUs

One of the biggest technical challenges in developing software is taking advantage of multiple CPUs. Processor speed has basically stalled. Intel and AMD are putting more and more CPUs into the same chip. Right now dual and quad core chips are becoming common. If you are talking two years away, then by Moore's Law, you will be seeing eight or more cores in most systems. If it is three years away, you could be seeing sixteen or more cores.

Currently, only very high end systems have multiple GPUs. We had one system at a company I used to work for that had four GPUs (all very high end stuff doing medical imaging). But just like CPUs, multiple GPUs are going to be more and more common.

The challenge of writing code that supports multiple processors working in parallel is the real challenge. Some argue that current computer languages do not support that well. In my experience, threads (which are supposed to be light weight processes) do not scale well on multi-core CPU systems. We had a Java application with six main threads running on a system with two dual core chips (total of 4 cores) and we saw almost no performance gain for that application over running on a single core CPU. The system performed better because the system basically gave one CPU to the SQL server and another to the OS, but our multi-threaded application did not get any faster. You could blame that on Java, but putting the blame there does not solve the problem. Also we had similar problems with a multi-threaded application written in C++. The current state of compiler and operating system support for multiple CPUs is limited.

Right now I am drooling over the new Alienware M17x. You can get a laptop with a quad core CPU and dual GPUs. That would be a good replacement for aging Alienware laptop. It has been a great system, but it is getting old.

I hope that the operating system and programs will take full advantage of the 16 CPUs and 8 GPUs I hope to have in the computer I hope to have in a couple of years.

No comments: