xref: /oneTBB/examples/README.md (revision 0a2b3987)
1# Code Samples of oneAPI Threading Building Blocks (oneTBB)
2This directory contains example usages of oneAPI Threading Building Blocks.
3
4| Code sample name | Description
5|:--- |:---
6| getting_started/sub_string_finder | Example referenced by the [oneAPI Threading Building Blocks Get Started Guide](https://software.intel.com/content/www/us/en/develop/documentation/get-started-with-onetbb/top.html). Finds largest matching substrings.
7| concurrent_hash_map/count_strings | Concurrently inserts strings into a `concurrent_hash_map` container.
8| concurrent_priority_queue/shortpath | Solves the single source shortest path problem using a  `concurrent_priority_queue` container.
9| graph/binpack | A solution to the binpacking problem using a `queue_node`, a `buffer_node` and `function_node`s.
10| graph/cholesky | Several versions of Cholesky Factorization algorithm implementation.
11| graph/dining_philosophers | An implementation of dining philosophers in graph using the reserving `join_node`.
12| graph/fgbzip2 | A parallel implementation of bzip2 block-sorting file compressor.
13| graph/logic_sim | An example of a collection of digital logic gates that can be easily composed into larger circuits.
14| graph/som | An example of a Kohonen Self-Organizing Map using cancellation.
15| parallel_for/game_of_life | Game of life overlay.
16| parallel_for/polygon_overlay | polygon overlay.
17| parallel_for/seismic | Parallel seismic wave simulation.
18| parallel_for/tachyon | Parallel 2-D raytracer/renderer.
19| parallel_for_each/parallel_preorder | Parallel preorder traversal of a graph.
20| parallel_pipeline/square | Another string transformation example that squares numbers read from a file.
21| parallel_reduce/convex_hull | Parallel version of convex hull algorithm (quick hull).
22| parallel_reduce/primes | Parallel version of the Sieve of Eratosthenes.
23| task_arena/fractal |The example calculates two classical Mandelbrot fractals with different concurrency limits.
24| task_group/sudoku | Compute all solutions for a Sudoku board.
25| test_all/fibonacci | Compute Fibonacci numbers in different ways.
26
27## System Requirements
28"Refer to the [System Requirements](https://software.intel.com/content/www/us/en/develop/articles/intel-oneapi-threading-building-blocks-system-requirements.html) for the list of supported hardware and software".
29
30### Graphical User Interface (GUI)
31Some examples (fractal, seismic, tachyon, polygon_overlay) supports different GUI modes, which may be defined via the `EXAMPLES_UI_MODE` CMake variable. Supported values are:
32- Cross-platform:
33    - `con` - Console mode (Default).
34- Windows:
35    - `gdi` - `GDI+` based implementation.
36    - `d2d` - `Direct 2D` based implementation. May offer superior performance, but can only be used if the Microsoft* DirectX* SDK is installed on your system(`DXSDK_DIR` should be defined).
37- Linux:
38    - `x` - `X11` based implementation. Also `libXext` may be required to display the output correctly.
39- MacOS:
40    - `mac` - `OpenGL` based implementation. Also requires the `Foundation` and `Cocoa` libraries availability.
41