]> git.baikalelectronics.ru Git - kernel.git/commit
ext3: speed up file creates by optimizing rec_len functions
authorEric Sandeen <sandeen@redhat.com>
Tue, 7 Dec 2010 17:55:27 +0000 (11:55 -0600)
committerJan Kara <jack@suse.cz>
Mon, 10 Jan 2011 18:04:07 +0000 (19:04 +0100)
commit6ce9229f6cc99af2e89a43e5f81437a120ad39c9
treedea6bfdc5c0e3e34b2bd74cffae147220c4cc855
parentaed12002fbc5cb95ff1824d580b3e71aca01c561
ext3: speed up file creates by optimizing rec_len functions

The addition of 64k block capability in the rec_len_from_disk
and rec_len_to_disk functions added a bit of math overhead which
slows down file create workloads needlessly when the architecture
cannot even support 64k blocks, thanks to page size limits.

Similar changes already exist in the ext4 codebase.

The directory entry checking can also be optimized a bit
by sprinkling in some unlikely() conditions to move the
error handling out of line.

bonnie++ sequential file creates on a 512MB ramdisk speeds up
from about 77,000/s to about 82,000/s, about a 6% improvement.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Jan Kara <jack@suse.cz>
fs/ext3/dir.c
include/linux/ext3_fs.h