diff options
| author | Jason A. Donenfeld <Jason@zx2c4.com> | 2021-05-20 14:15:43 +0200 |
|---|---|---|
| committer | Michael Bestas <mkbestas@lineageos.org> | 2021-07-23 02:44:46 +0300 |
| commit | 761fe263f7dc979cc5f586af027bff3c512aa06b (patch) | |
| tree | 23d712f596152fecc14a7dd9ea3a1a06e7fa5fd9 /scripts/patch-kernel | |
| parent | f911325706b63033183dacb76f6abb2060dae01a (diff) | |
peer: allocate in kmem_cache
With deployments having upwards of 600k peers now, this somewhat heavy
structure could benefit from more fine-grained allocations.
Specifically, instead of using a 2048-byte slab for a 1544-byte object,
we can now use 1544-byte objects directly, thus saving almost 25%
per-peer, or with 600k peers, that's a savings of 303 MiB. This also
makes wireguard's memory usage more transparent in tools like slabtop
and /proc/slabinfo.
Suggested-by: Arnd Bergmann <arnd@arndb.de>
Suggested-by: Matthew Wilcox <willy@infradead.org>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Change-Id: I6564caccfeb39a7c016050b832a284f2cac7b99f
Diffstat (limited to 'scripts/patch-kernel')
0 files changed, 0 insertions, 0 deletions
