libmalloc has poor performance for cross-thread frees. |
||
Issue descriptionThere are several magazines for allocations [segmented by allocation size]. The large magazine has a global lock. For the small magazine, there is a lock per logical cpu. Allocations grab the lock of the current CPU, but frees grab the lock of the CPU at time of allocation. There will be heavy lock contention if one thread allocates and another frees. I didn't check the code for tiny/nano magazines. lizeb@ mentioned that tcmalloc has better performance for this use case.
,
Oct 19
#1: Is that something we have contemplated? Do you know if there's a bug/doc/thread?
,
Oct 19
> Is that something we have contemplated? I think this comes up every once in a while, but we've never put serious thought into it [that I'm aware of]. > Do you know if there's a bug/doc/thread? I don't know of any. Filed https://bugs.chromium.org/p/chromium/issues/detail?id=897152 |
||
►
Sign in to add a comment |
||
Comment 1 by erikc...@chromium.org
, Oct 19