4 ms·
Interesting. I wonder if Python has the same problem. (Last time I observed serious fragmentation in Python, I was using Python 2, though.)
by wozer 6y ago
Interesting. I wonder if Python has the same problem. (Last time I observed serious fragmentation in Python, I was using Python 2, though.)
- jashmatthews 6y agoYup https://zapier.com/engineering/celery-python-jemalloc/ https://zapier.com/engineering/celery-python-jemalloc/ CPython is less affected than CRuby because CPython has a specialized allocator called obmalloc for small objects up to 512 bytes. CRuby < 2.6 doesn't have an allocator like this and hits malloc for anything bigger than 24 bytes. 2.6+ can allocate using the "transient heap" which helps but isn't as effective as CPython's obmalloc.