3 ms·
The TL;DR is really: No idea what I'm doing here, so I might as well blog about it. An application doesn't magically allocate less memory when running under a
by xorcist 12y ago
The TL;DR is really: No idea what I'm doing here, so I might as well blog about it.
An application doesn't magically allocate less memory when running under a different kernel. The underlying idea must be that LLVM wins over gcc in a real world scenario, which certainly would be interesting, but there is really nothing to suggest it here.
- AlisdairO 12y ago> An application doesn't magically allocate less memory when running under a different kernel. Different default allocator can make a difference, though - FreeBSD defaults to jemalloc iirc.
- fulafel 12y agoIt's definitely not a deep technical analysis as it's not written by a kernel engineer, but it's also plausible. VM management and swapping can and do have implementation quality differences on this scale. The kernel VM is all about heuristics. In a memory pressure situation, it's constantly discarding cached pages that it thinks are better used for other data, making decisions about whether to swap out some data to make room for more cache, etc. If you remember/look at the history of Linux VM and swap behaviour tuning and algorithms, there have been large improvements and regressions in this area historically.
- xorcist 12y agoAbsolutely, but the claim here is entirely different, "my application used less memory when running on FreeBSD". While within the realm of the possible, it is more likely it is running on a completely different configuration, or "memory used" changed meaning, or both.
- fulafel 12y agoThe explicit swapping part was there in the desktop section. But even the server part, due to vague phrasing, could mean that his VMs are doing OK with 500MB under FreeBSD and needed more with Linux. But yeah, it might be due to different configurations or misinterpretation of memory stats too.