Introducing Intel(R) Array Building Blocks
You can view Intel(R) Array Building Blocks (Intel(R) ArBB) from several different perspectives.
It can be seen as any of the following:
- A language. Intel(R) ArBB is a full programming language that supports the specification and implementation of arbitrary parallel computations. However, it is an embedded language since it expresses all its types, control flow constructs, and operators using standard C++ functionality. Intel(R) ArBB can be seen as a parallel extension to C++ that you can use together with existing C++ functionality.
- A programming model. Intel(R) ArBB supports a programming model based on the dynamic composition of structured patterns of parallel computation. It enables the construction of parallel programs by expressing operations at the aggregate data collection level as well as at the element level. Intel(R) ArBB supports a set of deterministic parallel patterns with consistent serial interpretations. Composing programs using these patterns results in deterministic programs that avoid race conditions and deadlocks by construction and are easier to debug and understand than unstructured parallel programs.
- An abstract virtual machine. Intel(R) ArBB semantics are based on the underlying abstract model of parallelism often referred to as the Intel ArBB Virtual Machine (VM). Abstract parallel operations expressed in the VM semantics are automatically mapped onto the underlying hardware mechanisms that enhance performance. These mechanisms include vector instructions, multiple cores, prefetching and streaming for parallelizing memory access. However, the high-level abstraction of the Intel(R) ArBB virtual machine avoids dependencies on the details of the underlying system, making Intel(R) ArBB code more portable and easier to write and maintain. Finally, the VM has its own API that can be used to implement front-ends for other languages in addition to C++.
- An Application Programming Interface (API). Intel(R) ArBB uses C++ templates to introduce new types. It also uses operator overloading and library calls to introduce new operators. To compile Intel(R) ArBB programs, you can use it as a library with standard C++ compilers. All Intel(R) ArBB functionality is implemented through its library interface. Of particular interest are the
call
and map
functions that compile sequences of operations expressed over Intel ArBB types and can apply them in turn as aggregate and element-wise parallel operations. These functions take as arguments the name and parameters of a standard C++ function that uses Intel ArBB types. The dynamic compiler retargets the expressed sequences of operations for the target architecture and caches the dynamically compiled machine language for reuse on subsequent call
or map
invocations. You can also translate Intel ArBB functions in advance and store them in the closure
objects for later use. Thus, Intel ArBB provides a full metaprogramming API for dynamically generating and manipulating parallel code. This provides a generic programming interface that can help you avoid the modularity overhead of C++.