binder: Reserve caches for small, high-frequency memory allocations
Most of binder's memory allocations are tiny, and they're allocated
and freed extremely frequently. The latency from going through the page
allocator all the time for such small allocations ends up being quite
high, especially when the system is low on memory. Binder is
performance-critical, so this is suboptimal.
Instead of using kzalloc to allocate a struct every time, reserve caches
specifically for allocating each struct quickly.
Signed-off-by:
Sultan Alsawaf <sultan@kerneltoast.com>
kondors1995: Backported to 3.18
Loading
Please register or sign in to comment