Skip to content

Latest commit

 

History

History
38 lines (25 loc) · 1.01 KB

README.md

File metadata and controls

38 lines (25 loc) · 1.01 KB

TBB Concurrent Queue (header only)

Build Status Apache License Version 2.0 Stable release

TBB Concurrent Queue is a header-only version of the Concurrent Queue provided by the library Threading Building Blocks (TBB).

Usage

#include <tbb/header_only/concurrent_queue.h>
#include <iostream>

int main() {

  tbb::concurrent_bounded_queue<int> queue;

  for (int i = 0; i < 10; i++)
  {
    queue.push(i);
  }

  int n;
  while (!queue.empty())
  {
    queue.pop(n);
    std::cout << n << std::endl;
  }

  return 0;
}

Documentation

Read the full documentation on the Intel Website