Josef Bacik <josef@xxxxxxxxxx> writes: > Btrfs (and I'd venture most other fs's) stores its indexes in nice disk order > for readdir, but unfortunately in the case of anything that stats the files in > order that readdir spits back (like oh say ls) that means we still have to do > the normal lookup of the file, which means looking up our other index and then > looking up the inode. What I want is a way to create dummy dentries when we > find them in readdir so that when ls or anything else subsequently does a > stat(), we already have the location information in the dentry and can go Funny I remember discussing this optimization a long time ago with Andrea. But the problem is still that it has the potential to pollute the dcache a lot when someone is reading a large directory. Consider the find / case. You don't want that to turn over all of your dcache. So if you do that you need some way to put the dummy dentries on a special LRU list that gets cleaned quickly and is kept small. -Andi -- ak@xxxxxxxxxxxxxxx -- Speaking for myself only -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html