lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.20.1709270358400.30866@nuc-kabylake>
Date:   Wed, 27 Sep 2017 04:03:01 -0500 (CDT)
From:   Christopher Lameter <cl@...ux.com>
To:     Michal Hocko <mhocko@...nel.org>
cc:     Johannes Thumshirn <jthumshirn@...e.de>,
        Pekka Enberg <penberg@...nel.org>,
        David Rientjes <rientjes@...gle.com>,
        Joonsoo Kim <iamjoonsoo.kim@....com>,
        Andrew Morton <akpm@...ux-foundation.org>, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org,
        Damien Le Moal <damien.lemoal@....com>,
        Christoph Hellwig <hch@....de>
Subject: Re: [PATCH 1/6] mm: add kmalloc_array_node and kcalloc_node

On Wed, 27 Sep 2017, Michal Hocko wrote:

> > Introduce a combination of the two above cases to have a NUMA-node aware
> > version of kmalloc_array() and kcalloc().
>
> Yes, this is helpful. I am just wondering why we cannot have
> kmalloc_array to call kmalloc_array_node with the local node as a
> parameter. Maybe some sort of an optimization?

Well the regular kmalloc without node is supposed to follow memory
policies. An explicit mentioning of a node requires allocation from that
node and will override memory allocation policies.

Note that node local policy is the default for allocations but that can be
overridden by the application or at the command line level. Assumptions
that this is always the case come up frequently but if we do that we will
loose the ability to control memory locality for user space.


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ