diff options
| author | Andrew Morton <akpm@zip.com.au> | 2002-06-02 03:22:29 -0700 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2002-06-02 03:22:29 -0700 |
| commit | 7e7382fd4079d948c2cd3799e39a9e963da35baf (patch) | |
| tree | 2374dfe047d40dcac1c4f2526149f0b86fdc21f2 /include | |
| parent | 02eaba7ffd145ef1389f4adc420f94af20ab3068 (diff) | |
[PATCH] speed up writes
Speeds up generic_file_write() by not calling mark_inode_dirty() when
the mtime and ctime didn't change.
There may be concerns over the fact that this restricts mtime and ctime
updates to one-second resolution. But the interface doesn't support
that anyway - all the filesystem knows is that its dirty_inode()
superop was called. It doesn't know why.
So filesystems which support high-resolution timestamps already need to
make their own arrangements. We need an update_mtime i_op to support
those properly.
time to write a one megabyte file one-byte-at-a-time:
Before:
ext3: 24.8 seconds
ext2: 4.9 seconds
reiserfs: 17.0 seconds
After:
ext3: 22.5 seconds
ext2: 4.8 seconds
reiserfs: 11.6 seconds
Not much improvement because we're also calling expensive
mark_inode_dirty() functions when i_size is expanded. So compare the
overwrite case:
time dd if=/dev/zero of=foo bs=1 count=1M conv=notrunc
ext3 before: 20.0 seconds
ext3 after: 9.7 seconds
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions
