tbb_allocator Template Class

Summary

Template class for scalable memory allocation if available; possibly non-scalable otherwise.

Syntax

template<typename T> class tbb_allocator

Header

#include "tbb/tbb_allocator.h"

Description

A tbb_allocator allocates and frees memory via the Intel® Threading Building Blocks (Intel® TBB) malloc library if it is available, otherwise it reverts to using malloc and free.

Tip

Set the environment variable TBB_VERSION to 1 to find out if the Intel TBB malloc library is being used.

 

For more complete information about compiler optimizations, see our Optimization Notice.