Re: [PATCH 15/18] fs: introduce a per-cpu last_ino allocator

From: Al Viro
Date: Fri Oct 08 2010 - 05:57:04 EST


On Fri, Oct 08, 2010 at 04:21:29PM +1100, Dave Chinner wrote:
> From: Eric Dumazet <eric.dumazet@xxxxxxxxx>
>
> new_inode() dirties a contended cache line to get increasing
> inode numbers. This limits performance on workloads that cause
> significant parallel inode allocation.
>
> Solve this problem by using a per_cpu variable fed by the shared
> last_ino in batches of 1024 allocations. This reduces contention on
> the shared last_ino, and give same spreading ino numbers than before
> (i.e. same wraparound after 2^32 allocations).

FWIW, that one is begging to be split; what I mean is that there are
two classes of callers; ones that will set i_ino themselves anyway
and ones that really want i_ino invented. Two functions?
--
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/