2 ms·
Pretty much any malloc/free worth even considering using has thread-local arenas. On top of that, you can always go with custom allocators (such as bump pointer
by kllrnohj 4y ago
Pretty much any malloc/free worth even considering using has thread-local arenas. On top of that, you can always go with custom allocators (such as bump pointer arenas) with C/C++. There's no issue scaling across dozens or hundreds of CPU cores here. Heck, the most parallel of all parallelization in computing, GPU compute, regularly uses C/C++ as the source language.
Go, on the other hand, does have scaling issues. So do most GC'd languages in fact, as the GCs want to periodically park all threads to walk their stacks. Even the latest & greatest GCs, like Shenandoah, still gotta park all them threads periodically for milliseconds at a time.