kernel-ark/fs
Andrew Morton fe1dcbc4f3 [PATCH] jbd: fix transaction batching
Ben points out that:

  When writing files out using O_SYNC, jbd's 1 jiffy delay results in a
  significant drop in throughput as the disk sits idle.  The patch below
  results in a 4-5x performance improvement (from 6.5MB/s to ~24-30MB/s on my
  IDE test box) when writing out files using O_SYNC.

So optimise the batching code by omitting it entirely if the process which is
doing a sync write is the same as the one which did the most recent sync
write.  If that's true, we're unlikely to get any other processes joining the
transaction.

(Has been in -mm for ages - it took me a long time to get on to performance
testing it)

Numbers, on write-cache-disabled IDE:

/usr/bin/time -p synctest -n 10 -uf -t 1 -p 1 dir-name

Unpatched:
	40 seconds
Patched:
	35 seconds
Batching disabled:
	35 seconds

This is the problematic single-process-doing-fsync case.  With multiple
fsyncing processes the numbers are AFACIT unaltered by the patch.

Aside: performance testing and instrumentation shows that the transaction
batching almost doesn't help (testing with synctest -n 1 -uf -t 100 -p 10
dir-name on non-writeback-caching IDE).  This is because by the time one
process is running a synchronous commit, a bunch of other processes already
have a transaction handle open, so they're all going to batch into the same
transaction anyway.

The batching seems to offer maybe 5-10% speedup with this workload, but I'm
pretty sure it was more important than that when it was first developed 4-odd
years ago...

Cc: "Stephen C. Tweedie" <sct@redhat.com>
Cc: Benjamin LaHaise <bcrl@kvack.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-02-05 11:06:53 -08:00
..
9p [PATCH] v9fs: fix corner cases when flushing request 2006-02-03 08:32:06 -08:00
adfs
affs
afs
autofs
autofs4 [PATCH] autofs4 oops fix 2006-01-14 18:25:19 -08:00
befs
bfs
cifs [CIFS] Remove compiler warning 2006-01-27 18:36:11 -08:00
coda
configfs [PATCH] BUG_ON() Conversion in fs/configfs/ 2006-02-03 14:03:09 -08:00
cramfs
debugfs
devfs
devpts
efs return statement cleanup - kill pointless parentheses 2006-01-15 02:37:08 +01:00
exportfs [PATCH] exportfs: add find_acceptable_alias helper 2006-01-18 19:20:28 -08:00
ext2 [PATCH] quota: fix error code for ext2_new_inode() 2006-02-03 08:32:09 -08:00
ext3 [PATCH] Fix two ext[23] uninitialized warnings 2006-02-03 08:32:05 -08:00
fat [PATCH] fat: Fix truncate() write ordering 2006-02-03 08:32:10 -08:00
freevxfs
fuse [PATCH] fuse: fix request_end() vs fuse_reset_request() race 2006-02-05 11:06:51 -08:00
hfs [PATCH] hfs: cleanup HFS prints 2006-01-18 19:20:23 -08:00
hfsplus [PATCH] hfs: set type/creator for symlinks 2006-01-18 19:20:23 -08:00
hostfs
hpfs
hppfs
hugetlbfs [PATCH] mm: hugepage accounting fix 2006-02-01 08:53:15 -08:00
isofs [PATCH] isofs: remove d_splice_alias NULL check from isofs_lookup 2006-01-14 18:27:12 -08:00
jbd [PATCH] jbd: fix transaction batching 2006-02-05 11:06:53 -08:00
jffs [PATCH] fs/jffs/intrep.c: 255 is unsigned char 2006-02-03 08:32:05 -08:00
jffs2 [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
jfs
lockd NLM: Ensure that nlmclnt_cancel_callback() doesn't loop forever 2006-02-01 12:52:23 -05:00
minix
msdos
ncpfs [PATCH] ncpfs: remove kmalloc wrapper 2006-01-14 18:27:12 -08:00
nfs NFSv3: fix sync_retry in direct i/o NFS 2006-02-01 12:52:25 -05:00
nfs_common
nfsd [PATCH] knfsd: Restore recently broken ACL functionality to NFS server 2006-02-01 08:53:09 -08:00
nls
ntfs
ocfs2 [PATCH] ocfs2: don't wait on recovery when locking journal 2006-02-03 14:05:14 -08:00
openpromfs
partitions [PATCH] partitions: Read Rio Karma partition table 2006-01-16 23:15:29 -08:00
proc [PATCH] disable per cpu intr in /proc/stat 2006-02-03 08:32:07 -08:00
qnx4
ramfs
reiserfs [PATCH] someone broke reiserfs V3 mount options, this fixes it 2006-02-03 08:32:03 -08:00
relayfs
romfs
smbfs [PATCH] smbfs readdir vs signal fix 2006-02-01 08:53:09 -08:00
sysfs
sysv correct email address of Manfred Spraul 2006-01-15 02:43:54 +01:00
udf [PATCH] UDF: Fix issues reported by Coverity in namei.c 2006-02-03 08:32:11 -08:00
ufs [PATCH] ufs: fix hang during `rm' 2006-02-03 08:32:04 -08:00
vfat
xfs [PATCH] Direct Migration V9: Avoid writeback / page_migrate() method 2006-02-01 08:53:17 -08:00
aio.c
attr.c
bad_inode.c
binfmt_aout.c
binfmt_elf_fdpic.c
binfmt_elf.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
binfmt_em86.c
binfmt_flat.c
binfmt_misc.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
binfmt_script.c
binfmt_som.c
bio.c [BLOCK] A few kerneldoc fixups 2006-01-31 15:24:34 +01:00
block_dev.c
buffer.c [PATCH] Trivial optimization of ll_rw_block() 2006-02-03 08:32:10 -08:00
char_dev.c [PATCH] convert /proc/devices to use seq_file interface 2006-01-14 18:25:19 -08:00
compat_ioctl.c
compat.c [PATCH] compat: fix compat_sys_openat and friends 2006-02-01 22:04:33 -08:00
dcache.c [PATCH] make "struct d_cookie" depend on CONFIG_PROFILING 2006-02-03 08:32:04 -08:00
dcookies.c
direct-io.c [PATCH] fix O_DIRECT read of last block in a sparse file 2006-02-03 08:32:07 -08:00
dnotify.c
dquot.c
drop_caches.c
eventpoll.c
exec.c [PATCH] vfs: *at functions: core 2006-01-18 19:20:29 -08:00
fcntl.c [PATCH] fcntl F_SETFL and read-only IS_APPEND files 2006-02-03 08:32:07 -08:00
fifo.c
file_table.c
file.c [PATCH] percpu data: only iterate over possible CPUs 2006-02-05 11:06:51 -08:00
filesystems.c
fs-writeback.c
inode.c [PATCH] DocBook: fix some kernel-doc comments in fs and block 2006-02-01 08:53:27 -08:00
inotify.c [PATCH] add missing syscall declarations 2006-01-18 19:20:22 -08:00
ioctl.c
ioprio.c
Kconfig o Remove confusing Kconfig text for CONFIGFS_FS. 2006-02-03 13:47:17 -08:00
Kconfig.binfmt
libfs.c [PATCH] debugfs: hard link count wrong 2006-02-03 08:32:11 -08:00
locks.c
Makefile
mbcache.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
mpage.c
namei.c [PATCH] DocBook: fix some kernel-doc comments in fs and block 2006-02-01 08:53:27 -08:00
namespace.c [PATCH] add /sys/fs 2006-01-16 23:15:29 -08:00
nfsctl.c [PATCH] EDAC: atomic scrub operations 2006-01-18 19:20:30 -08:00
open.c [PATCH] vfs: *at functions: core 2006-01-18 19:20:29 -08:00
pipe.c [PATCH] Unlinline a bunch of other functions 2006-01-14 18:27:06 -08:00
pnode.c
pnode.h
posix_acl.c
quota_v1.c
quota_v2.c [PATCH] quota_v2: printk warning fixes 2006-02-03 08:32:03 -08:00
quota.c
read_write.c
readdir.c
select.c [PATCH] Add pselect/ppoll system call implementation 2006-01-18 19:20:30 -08:00
seq_file.c
stat.c [PATCH] vfs: *at functions: core 2006-01-18 19:20:29 -08:00
super.c
xattr_acl.c
xattr.c