3 ms·
> I suspect that any parallel primitive that needs to allocate anything is going to be too slow to achieve any gains on this problem Even by using TLS instead
by oscargrouch 13y ago
> I suspect that any parallel primitive that needs to allocate anything is going to be too slow to achieve any gains on this problem
Even by using TLS instead of the global heap?
- pcwalton 13y agoAny decent multithreaded allocator (like the one in glibc) is going to basically make those equivalent, and if the parallel version is 10x slower than the sequential one then I suspect most of the overhead is in allocating stacks. You could try tcmalloc/jemalloc but I suspect you won't see huge gains—the overhead of allocation in general (cache pressure, etc.) seems to be swamping any gains.