| Intel rev's multicore C++ libraries |
Jul. 22, 2008
Intel released a new version of its programming tool designed to help adapt existing applications to multi-core processors. Version 2.1 of Intel Threading Building Blocks (TBB) offers performance improvements, adds a portable affinity mechanism, and improves the task scheduler, easing development for GUIs, network I/O, and artificial intelligence, says Intel.
TBB is a cross-platform, portable library aimed at improving the performance of C++ applications on multi-core processors, such as Intel's recently released Core 2 Duo T9400. Supporting Windows, Linux, Mac OS X, and Solaris, the library comprises a 120KB runtime combined with "template libraries" linked in at compile time, says Intel. TBB implements a task scheduler, memory allocator, and timing counter, along with various generic parallel algorithms, thread-safe containers, and synchronization primitives.
 Overview of TBB 2.1 enhancements
Announced this week at O'Reilly's tenth-annual OSCON (Open Source Convention) in Portland, Ore., Version 2.1 improves a number of TBB components, including the task scheduler and memory allocator, says Intel. It also adds the following new components:- tbb_threadabstraction
- parallel_do
- tbb_allocator
- blocked_range3d
- recursive_mutex
Previously, the task scheduler handled blocking tasks using non-portable native threads, which Intel says required additional thread management. The new tbb_threadabstraction component is said to streamline development by supporting blocking tasks without interfering with computational work. Another key feature is the new portable affinity mechanism, aimed at reducing cache changes in chained parallel operations.
  Task scheduling in TBB 2.0 (left) and TBB 2.1 (right), which adds blocking task support (Click either to enlarge) Additional touted new features in TBB 2.1 include:- Support for 1-, 2- or 3-D ranges for more efficient work breakdown
- Better performance throughout algorithms and containers
- Choice of any memory allocator
- Improved APIs
- Better support for expert users using "black belt" hooks
- Support for task cancellation and exceptions
- A compile configuration plugin that makes the library easier to use in Microsoft's Visual Studio
TBB is said to simplify parallel programming by avoiding the low-level coding required with threading packages such as p-threads or Windows threads. It was designed to support "any compiler," including Intel's commercial compilers and the GNU Compiler Collection (GCC), and Intel's commercial compilers, says the company.
 O'Reilly's Intel TBB book (Click for details) |
A year ago, OSCON host O'Reilly published the book Intel Threading Building Blocks by James Reinders (see image). According to the author, TBB helps developers adapt their existing applications to perform well on multi-core processors, without having to understand parallel computing theory. They simply choose those parts of their C++ applications that could benefit most from parallelism -- searching and indexing functions, for instance -- and then re-write them around the function calls available in TBB. For further information on the book, see the coverage on our sister website LinuxDevices.com, here. Availability
TBB 2.1 is available in both open-source and commercial versions starting July 23, says Intel. More information on the free, open-source version should be available here, and more details on Intel's commercial version may be found here.
Related stories:
(Click here for further information)
|
|
|
|