We're using tbb42_20131118oss version for Linux 64bit ( CentOS 5 ) in our product. Recently, following issue was discovered - for cases with large memory allocation we've noticed significant performance degradation after reaching some "critical point" in terms of memory. Specific example is:
1. Machine has about 1 terabyte of memory, it is mostly free, only our application was running.
2. Our application runs some algorithm that builds some data structure of the large size. And, ideally, we're expecting to see approximately constant memory increase over time till the end.
3. But, until physical memory is not reaching around 250-300 Gb, algorithm works relatively fast. After reaching this "critical point", it slows down dramatically ( i.e., the same portion of job which was completed in 5 minutes before reaching critical point, after critical point was completed in about 5 hours ). Finally, it finishes with physical memory about 465 Gb. And runtime profiler shows definite bottleneck in tbbmalloc.
4. It is worth to mention again, that machine is free, there is plenty of free memory, and only our process consumes most of CPU resources also. We also do not see any fragmentation of memory in our application.
We've tried to do not link tbbmalloc at all ( in this case, standard malloc is used ), but it causes crashes in multi-threaded runs, so it seems like we cannot use TBB without linking tbbmalloc.
It is also worth to mention that while using older version of TBB ( 2.2 ), we were not able to finish the run at all, it gave us St9bad_alloc error while reaching certain amount of memory ( ~ 400 Gb ). With 4.2 it is goes through but with unacceptable runtime, unfortunately.
Could you please advise us something?