3 ms·
Very very few OSX apps use an alternate allocator so this was probably not noticed. Having written a commercial memory allocator before (for MacOS prior to OSX)
by coldcode 12y ago
Very very few OSX apps use an alternate allocator so this was probably not noticed. Having written a commercial memory allocator before (for MacOS prior to OSX) the one in OSX is actually quite good for most people. I don't know why Mozilla decided they needed jemalloc but maybe it tested better for their usage.
Still you would think tracking what's written to such a common directory would have been seen by someone at Apple. Firefox isn't exactly obscure.
- deleted 12y ago[deleted]
- acdha 12y agojemalloc goes back to Firefox 3: http://blog.pavlov.net/2007/12/04/vlad-and-analysis-of-dtrace-was-used/ http://blog.pavlov.net/2007/12/04/vlad-and-analysis-of-dtrac... http://blog.pavlov.net/2008/03/11/firefox-3-memory-usage/ http://blog.pavlov.net/2008/03/11/firefox-3-memory-usage/ It looks like that was driven by cross-platform concerns – I don't know how good the OS X allocator was in that era but it looks like most of the benchmarking focused on Windows and having a single malloc which performed well on all of their platforms. At that time, Firefox still supported at least as far back as Windows 2000 and the rise of consumer Mac usage hadn't reached current levels.
- coldcode 12y agoThe WinHeap allocator before 7 was pretty awful, but apparently improved with 7. Chrome is actually using it (or at least thinking of it). It still amazes me that allocation is still a hard problem 15 years after I wrote mine.
- duaneb 12y agoThe performance of the memory allocator is very much load-specific on darwin these days, and it would be easy to justify jemalloc. It's certainly not a poor choice of an allocator.
- acdha 12y agoAgreed – absent some sort of benchmark showing major, hard-to-solve problems I'd assume that using one decent allocator everywhere would be a net win versus having to deal with platform-specific variations on at least 3 OSes.