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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 25 Jul 2017 15:38:33 -0400
From:   Josef Bacik <josef@...icpanda.com>
To:     Dennis Zhou <dennisz@...com>
Cc:     Tejun Heo <tj@...nel.org>, Christoph Lameter <cl@...ux.com>,
        Josef Bacik <josef@...icpanda.com>,
        linux-kernel@...r.kernel.org, linux-mm@...ck.org,
        kernel-team@...com, Dennis Zhou <dennisszhou@...il.com>
Subject: Re: [PATCH v2 20/23] percpu: update free path to take advantage of
 contig hints

On Mon, Jul 24, 2017 at 07:02:17PM -0400, Dennis Zhou wrote:
> From: "Dennis Zhou (Facebook)" <dennisszhou@...il.com>
> 
> The bitmap allocator must keep metadata consistent. The easiest way is
> to scan after every allocation for each affected block and the entire
> chunk. This is rather expensive.
> 
> The free path can take advantage of current contig hints to prevent
> scanning within the start and end block.  If a scan is needed, it can
> be done by scanning backwards from the start and forwards from the end
> to identify the entire free area this can be combined with. The blocks
> can then be updated by some basic checks rather than complete block
> scans.
> 
> A chunk scan happens when the freed area makes a page free, a block
> free, or spans across blocks. This is necessary as the contig hint at
> this point could span across blocks. The check uses the minimum of page
> size and the block size to allow for variable sized blocks. There is a
> tradeoff here with not updating after every free. It is possible a
> contig hint in one block can be merged with the contig hint in the next
> block. This means the contig hint can be off by up to a page. However,
> if the chunk's contig hint is contained in one block, the contig hint
> will be accurate.
> 
> Signed-off-by: Dennis Zhou <dennisszhou@...il.com>

Reviewed-by: Josef Bacik <jbacik@...com>

Thanks,

Josef

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ