JFFS3 & performance

Jörn Engel joern at wohnheim.fh-wedel.de
Thu Jan 20 11:13:07 EST 2005


On Thu, 20 January 2005 18:37:41 +0300, Artem B. Bityuckiy wrote:
> 
> > Not sure.  What are GIGs and PIGs?
> Shit :-)

First pigs, now this.  You have a filthy language. ;)

> I meant PIDs and GIDs :-)

Doesn't work.  Those are per inode, unless you want all files to have
the same owner.
What would work, on the other hand, is to seperate inodes and data
nodes.  PID, GID and all the other inode fields are needed only once,
not for every chunk of data belonging to that inode.


And while we're at it, some other fields from the inodes should be
removed.

	jint32_t atime;      /* Last access time.  */
	jint32_t mtime;      /* Last modification time.  */
	jint32_t ctime;      /* Change time.  */

Who would want to mount jffs3 _without_ noatime?  In fact, look at
fs/jffs2/super.c:
        sb->s_flags = flags | MS_NOATIME;

For mtime and ctime, those could be collapsed into one.  Not sure if
that makes sense.

	jint32_t dsize;	     /* Size of the node's data. (after decompression) */

In most cases, dsize will be 4k.  So we can just uncompress into the
page and ignore the flag.  For the last page of a file, we can do the
same, even though the dsize is different.
In the remaining cases, we'd have to uncompress to a buffer of 4k (or
more, if we go for 64k nodes someday) and memcpy.

Might be worth the effort, even if it's just 4 bytes.

	uint8_t usercompr;   /* Compression algorithm requested by the user */

Not exactly sure how this is used.  The code appears to either ignore
it or to be buggy, if this is ever nonzero.  But I could be wrong.

Jörn

-- 
It does not matter how slowly you go, so long as you do not stop.
-- Confucius




More information about the linux-mtd mailing list