Good ideas and conversation. No ads, no tracking. Login or Take a Tour!
Curious on two fronts about this:
1) I've noticed something related to his comment about programs trying to be more clever than the kernel in other situations, too. Java, glib, and other libraries/languages will try to wrap malloc() with their own memory allocator, which will cache memory, so freeing the objects doesn't actually give that memory back to the OS for other processes to use. Is this necessarily intelligent design? 2) How do fancier languages than C handle memory allocation with respect to multiple processors? Do they just malloc and take the performance hit? Or are they more clever? Is the design pattern mentioned in the post generalizable to most cases?