[lkml]   [2003]   [May]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH] kmalloc_percpu
    Rusty Russell <> wrote:
    > It's a tradeoff, but I think it's worth it for a kmalloc_percpu which
    > is fast, space-efficient and numa-aware, since the code is needed
    > anyway.

    I don't beleive that kmalloc_percpu() itself needs to be fast, as you say.

    The code is _not_ NUMA-aware. Is it?

    > How about a compromise like the following (scaled with mem)?
    > Untested, but you get the idea...

    > + /* Plenty of memory? 1GB = 64k per-cpu. */
    > + pool_size = max(((long long)num_physpages << PAGE_SHIFT) / 16384,
    > + (long long)pool_size);

    On 64GB 32-way that's 128MB of lowmem. Unpopular. I'd settle for a __setup
    thingy here, and a printk when the memory runs out.

    btw, what's wrong with leaving kmalloc_percpu() as-is, and only using this
    allocator for DEFINE_PERCPU()?

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2005-03-22 13:35    [W:0.022 / U:21.644 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site