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]
Date:	Sun, 31 Mar 2013 21:24:03 -0400
From:	Theodore Ts'o <tytso@....edu>
To:	Lukas Czerner <lczerner@...hat.com>
Cc:	linux-ext4@...r.kernel.org
Subject: Re: [PATCH 1/2 v3] ext4: Make ext4_block_in_group() much more
 efficient

On Wed, Mar 27, 2013 at 04:35:40PM +0100, Lukas Czerner wrote:
> Currently in when getting the block group number for a particular block
> in ext4_block_in_group() we're using ext4_get_group_no_and_offset()
> which uses do_div() to get the block group and the remainer which is
> offset within the group.
> 
> We don't need all of that in ext4_block_in_group() as we only need to
> figure out the group number.
> 
> This commit changes ext4_block_in_group() to calculate group number
> directly. This shows as a big improvement with regards to cpu
> utilization. Measuring fallocate -l 15T on fresh file system with perf
> showed that 23% of cpu time was spend in the
> ext4_get_group_no_and_offset(). With this change it completely
> disappears from the list only bumping the occurrence of
> ext4_init_block_bitmap() which is the biggest user of
> ext4_block_in_group() by 4%. As the result of this change on my system
> the fallocate call was approx. 10% faster.
> 
> However since there is '-g' option in mkfs which allow us setting
> different groups size (mostly for developers) I've introduced new per
> file system flag whether we have a standard block group size or not. The
> flag is used to determine whether we can use the bit shift optimization
> or not.
> 
> Signed-off-by: Lukas Czerner <lczerner@...hat.com>

Thanks, applied.

						- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ