FastFlow  SVN-r182-Aug-14-2014
A high-level, lock-less, parallel programming (shared-memory) and distributed programming (distributed-memory) framework for multi-cores and many-cores systems
 All Classes Namespaces Files Functions Variables Typedefs Groups Pages
FastFlow Documentation

Parallel programming in FastFlow

FastFlow is a C++ parallel programming framework advocating high-level, pattern-based parallel programming. It chiefly supports streaming and data parallelism, targeting heterogenous platforms composed of clusters of shared-memory platforms, possibly equipped with computing accelerators such as NVidia GPGPUs, Xeon Phi, Tilera TILE64.

The main design philosophy of FastFlow is to provide application designers with key features for parallel programming (e.g. time-to-market, portability, efficiency and performance portability) via suitable parallel programming abstractions and a carefully designed run-time support.

Application scenarios

FastFlow is a general-purpose C++ programming framework for heterogenous parallel platforms. Like other high-level programming frameworks, such as Intel TBB and OpenMP, it simplifies the design and engineering of portable parallel applications. However, it has a clear edge in terms of expressiveness and performance with respect to other parallel programming frameworks in specific application scenarios, including, inter alia:

In other cases FastFlow is typically comparable to (and is some cases slightly faster than) state-of-the-art parallel programming frameworks such as Intel TBB, OpenMP, Cilk, etc. More details may be found on the performance page. A number of both micro-benchmarks and real-world applications has been developed with FastFlow (or ported from other parallel libraries) in order to asses its usability and performance, among the others:

The source code of (almost) all applications can be found in the FastFlow SVN repository under either LGPLv3 or GNU GPL license. The design of applications and their performance are described in research papers.


FastFlow comes as a C++ template library designed as a stack of layers that progressively abstracts out the programming of parallel applications. The goal of the stack is threefold: portability, extensibility, and performance. For this, all the three layers are realised as thin strata of C++ templates that are 1) seamlessly portable; 2) easily extended via subclassing; and 3) statically compiled and cross-optimised with the application. The terse design ensures easy portability on almost all OSes and CPUs with a C++ compiler. The main development platform is Linux/x86_64/gcc, but it has been tested also on various combinations of x86, x86_64, PPC, ARM, Tilera, NVidia with gcc, icc, Visual Studio on Linux, Mac OS, and Windows XP/7. The FastFlow core has been ported to ARM/iOS.


The FastFlow run-time support uses several techniques to efficiently support fine grain parallelism (and very high frequency streaming). Among these are:

FastFlow has been adopted by a number of research projects and third-party development initiatives, and has thus been tested in a variety of application scenarios: from systems biology to high-frequency trading.