[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Ext2fs patch
From: |
Yoshinori K. Okuji |
Subject: |
Re: Ext2fs patch |
Date: |
Wed, 29 Oct 2003 10:38:08 +0100 |
User-agent: |
KMail/1.5 |
On Tuesday 28 October 2003 21:46, Marco Gerards wrote:
> When reading the first block from a partition you won't read the first
> block. Normally there is no problem, but with util/i386/pc/biosdisk.c
> the partition is accessed separately and that means a negative sector
> number.
I understand.
> I wonder if it is wise to read blocks before the block you want to
> read. I think this usually doesn't make much sense. Usually
> filesystems are optimized to read forwards.
That's right. The current implementation is just for simplicity (in other
words, because I was lazy), so it is not perfect from performance point of
view.
However, I suspect that there would be no gain from making the cache system
work better by always reading blocks forwards. Normally, reading some blocks
at a time is quite fast (i.e. it does not differ from reading a single block
very much). And, even if it reads some unnecessary blocks, when you read a
file sequentially, the overhead would be negligible. As PUPA reads at most 8
blocks at a time, if you read more than 800 blocks sequentially, the overhead
is less 1%.
> The new patch is included in this mail. I've also updated the
> copyright years, I forgot some in my previous patch *blush*.
Now is the time to commit. :)
Okuji