Re: Attempt at "stat light" implementation

From: Ulrich Drepper
Date: Tue Apr 07 2009 - 15:31:09 EST


On Tue, Apr 7, 2009 at 11:21 AM, Andreas Dilger <adilger@xxxxxxx> wrote:
> There is one in OS/X called getattrlist, but it is quite complex and
> would require attribute handling wildly different than what the kernel
> and *nix applications are doing:
>
> http://www.manpagez.com/man/2/getattrlist/

I think this is overkill. There are two different tasks to do:

- speed up stat by providing a subset of the information

- provide a mechanism to get arbitrary attribute support and efficient
ways to get to it


Trying to force both of these tasks into one interface will partially
defeat the purpose of the first, creating a fast stat replacement. I
think these should be different interfaces (if the second type is
needed at all).

As for making the interface extendable. In all the years there hasn't
really been much need to extend the stat structure (ignoring extended
attributes). So, I'd not be worried about using a simple 32-bit
bitmask to select the fields to include in the fast stat.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/