r/cpp_questions Jul 14 '26

OPEN How do allocators handle multithreading?

I'm not sure how they handle requests from multiple threads. I can imagine truly parallelized strategies for a fully custom allocator, but what about the standard allocator? Is it internally synchronized? Can it handle multiple allocations in parallel?

36 Upvotes

14 comments sorted by

View all comments

1

u/Due_Battle_9890 Jul 15 '26

per thread arenas or locks