Questions tagged [tbb]

Intel Threading Building Blocks (also known as TBB) is an open-source portable C++ template library for writing software programs that take advantage of multi-core processors.

From Wikipedia:

Intel Threading Building Blocks (also known as TBB) is a C++ template library developed by Intel Corporation for writing software programs that take advantage of multi-core processors. The library consists of data structures and algorithms that allow a programmer to avoid some complications arising from the use of native threading packages such as POSIX threads, Windows threads, or the portable Boost Threads in which individual threads of execution are created, synchronized, and terminated manually.

Instead the library abstracts access to the multiple processors by allowing the operations to be treated as "tasks", which are allocated to individual cores dynamically.

Threading Building Blocks Homepage

Intel® Threading Building Blocks Tutorial

770 questions
53
votes
7 answers

C++ Parallelization Libraries: OpenMP vs. Thread Building Blocks

I'm going to retrofit my custom graphics engine so that it takes advantage of multicore CPUs. More exactly, I am looking for a library to parallelize loops. It seems to me that both OpenMP and Intel's Thread Building Blocks are very well suited for…
Adrian Grigore
  • 33,034
  • 36
  • 130
  • 210
33
votes
2 answers

Intel TBB vs Boost

I my new application I have flexibility to decide the use of library for multi-threading. So far I was using pthread. Now want to explore cross platform library. I zero in on TBB and Boost. I didn't understand what is the benefit of TBB over Boost.…
David
  • 4,634
  • 7
  • 35
  • 42
32
votes
2 answers

How does Intel TBB's scalable_allocator work?

What does the tbb::scalable_allocator in Intel Threading Building Blocks actually do under the hood ? It can certainly be effective. I've just used it to take 25% off an apps' execution time (and see an increase in CPU utilization from ~200% to…
timday
  • 24,582
  • 12
  • 83
  • 135
29
votes
1 answer

What are the differences between Intel TBB and Microsoft PPL?

I'm planning to start "playing" with task-based parallelism for a cross-platform project. I wanted to use Intel Threading Building Blocks. I'm starting with Windows and Visual Studio. As I just want to prototype for the moment, I'm thinking about…
Klaim
  • 67,274
  • 36
  • 133
  • 188
26
votes
10 answers

Any experiences with Intel's Threading Building Blocks?

Intel's Threading Building Blocks (TBB) open source library looks really interesting. Even though there's even an O'Reilly Book about the subject I don't hear about a lot of people using it. I'm interested in using it for some multi-level parallel…
Pat Notz
  • 208,672
  • 30
  • 90
  • 92
23
votes
2 answers

Scalable allocation of large (8MB) memory regions on NUMA architectures

We are currently using a TBB flow graph in which a) a parallel filter processes an array (in parallel with offsets) and puts processed results into an intermediate vector (allocated on the heap; mostly the vector will grow up to 8MB). These vectors…
muehlbau
  • 1,897
  • 13
  • 23
22
votes
4 answers

Simplest TBB example

Can someone give me a TBB example how to: set the maximum count of active threads. execute tasks that are independent from each others and presented in the form of class, not static functions.
Nelson Tatius
  • 7,693
  • 8
  • 47
  • 70
21
votes
3 answers

C++ tbb_debug.dll missing

I'm new with openCV and I tried followed some tutorials. Everything worked fine until I included: opencv2/imgproc/imgproc.hpp and used the filter2D function. I got the following error when I start my program: "The program can't start because…
programmer004
  • 211
  • 1
  • 2
  • 3
21
votes
7 answers

How to statically link to TBB?

How can I statically link the intel's TBB libraries to my application? I know all the caveats such as unfair load distribution of the scheduler, but I don't need the scheduler, just the containers, so it's ok. Anyways I know this can be done,…
Robert Gould
  • 68,773
  • 61
  • 187
  • 272
21
votes
3 answers

Number of threads used by Intel TBB

How does Intel TBB choose the number of threads to used for a parallel section? Is there some kind of specification available?
chris
  • 257
  • 1
  • 2
  • 7
19
votes
3 answers

C++17 parallel algorithm vs tbb parallel vs openmp performance

Since c++17 std library support parallel algorithm, I thought it would be the go-to option for us, but after comparing with tbb and openmp, I changed my mind, I found the std library is much slower. By this post, I want to ask for professional…
avocado
  • 2,615
  • 3
  • 24
  • 43
16
votes
8 answers

Parallelizing a for loop gives no performance gain

I have an algorithm which converts a bayer image channel to RGB. In my implementation I have a single nested for loop which iterates over the bayer channel, calculates the rgb index from the bayer index and then sets that pixel's value from the…
eladidan
  • 2,634
  • 2
  • 26
  • 39
15
votes
8 answers

Is this C++ implementation for an Atomic float safe?

Edit: The code here still has some bugs in it, and it could do better in the performance department, but instead of trying to fix this, for the record I took the problem over to the Intel discussion groups and got lots of great feedback, and if all…
Robert Gould
  • 68,773
  • 61
  • 187
  • 272
14
votes
2 answers

How to install TBB from source on Linux and make it work

I would like to know how to install TBB from source and make it work on a Linux system. I have had some problems when it comes using it, problems that don't appear if I install TBB via the package manager. In the TBB webpage, there are some…
Adri C.S.
  • 2,909
  • 5
  • 36
  • 63
13
votes
1 answer

Avoiding false positives with clang's ThreadSanitizer and TBB

Has anyone tried clang's ThreadSanitizer with Intel Threading Building Blocks (TBB)? My experience so far was that you will get a lot of warnings, even for relatively simple examples. Unfortunately, many of them seem to be false positives. In this…
Philipp Claßen
  • 41,306
  • 31
  • 146
  • 239
1
2 3
51 52