Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
23 Views

About tbb memory_pool & memory_pool_allocator

Dear experts

 

I am now considering our use of TBB's memory pool utilities (memory_pool and/or memory_pool_allocator etc).

Relating to it, I have some questions.

 

(1) About preview usage (TBB_PREVIEW_MEMORY_POOL)

I know the utilities are now under preview srage.

Is it safe or reliable to use them?

(Why is it kept the preview? And, is there the future plan to introduce it as a standard?)

 

(2) memory_pool_allocator for STL containers

I understand the main usage of memory pool is (1) allocate a lump of memory region previously (2) after that, allocate/deallocate each variable in fast way in the definite region. And, those of TBB are orientend to thread-safe usage, isn't it?

Correspondingly, I think this is useful for fast memory allocation/deallocation of STL containers such as std::vector and so on.

I am tackling the problems of high overhead for it, particularly for deallocation (call of destructor) of std::vector, std::unordered_map (and tbb::concurrent_vector, and tbb::concurrent_unordered_map).

Is it suited to make deallocation faster by using TBB's memory pool utilities?

 

Thank you for your cooperation.

 

Kind regards

 

 

 

0 Kudos
0 Replies