Why multicore matters.
For decades, faster processors meant better application performance but hotter, power-hungrier chips that were far from mobile-friendly. New multicore processors help solve the power problem, but don’t necessarily improve application performance. That’s where Leopard comes in, providing powerful tools that make it easy to reap the benefits of multicore computing.
Multiple cores, multiple efficiencies.
The new Leopard scheduler is very efficient at allocating tasks across multiple cores and processors. So Leopard spends less time managing tasks and more time performing computations. A new multithreaded network stack speeds up networking by handling network inputs and outputs in parallel.
Multicore apps in Leopard.
Apple engineers have updated several applications in Leopard — including Mail, Address Book, and Font Utility — to be fully multicore ready. Each of these apps breaks up processor-intensive actions into a series of more manageable steps that execute one by one on single-CPU computers and in parallel on newer, multicore systems. Cocoa uses the same technology to speed up Spotlight searches and Dictionary lookups.
Smooth operator.
How did Apple engineers pull this off? By using NSOperation, a breakthrough new API that optimizes applications for the world of multicore processing. Independent chunks of computation (operations) are added to NSOperationQueue, which dynamically determines how many operations to run in parallel based on the current architectures. So there’s no need to hand-code the complexities of threading and locking. You simply describe the operations in a program along with their dependencies. Cocoa takes care of the rest.
Pass it on.
To support the message-passing model popular in scientific computation — which has long needed to distribute calculations across multiple processes — Leopard includes the popular open source OpenMPI implementation of the MPI 2.0 standard. OpenMPI works with Xgrid, seamlessly supports both PowerPC- and Intel-based Mac computers, and makes it easy to add drivers for low-latency interconnects. And Xcode for Leopard includes the various MPI “compilers” (preprocessors) that streamline the process of writing MPI-compliant programs.
No comments:
Post a Comment