summaryrefslogtreecommitdiff
path: root/Libraries/LibC/netdb.cpp
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-09-16 10:19:44 +0200
committerAndreas Kling <awesomekling@gmail.com>2019-09-16 10:33:27 +0200
commit5d491fa1cdad08424449e129ba30baf76e7da6d1 (patch)
tree0b1ba86ca206f414f9bf9e0c759294dadc9d2458 /Libraries/LibC/netdb.cpp
parent1c692e87a647b26dc21825707b41b740a465a570 (diff)
downloadserenity-5d491fa1cdad08424449e129ba30baf76e7da6d1.zip
Kernel: Add a simple slab allocator for small allocations
This is a freelist allocator with static size classes that works as a complement to the generic kmalloc(). It's a lot faster than kmalloc() since allocation just means popping from the freelist. It's also significantly more compact when there are a lot of objects smaller than the minimum kmalloc chunk size (32 bytes.) This patch enables it for the Region and PhysicalPage classes. In the PhysicalPage (8 bytes) case, it's a huge improvement since we no longer waste 75% of the storage allocated. There are also a number of ways this can be improved, so let's keep working on it going forward.
Diffstat (limited to 'Libraries/LibC/netdb.cpp')
0 files changed, 0 insertions, 0 deletions