From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andi Kleen Subject: Re: [PATCH 15/18] fs: introduce a per-cpu last_ino allocator Date: Fri, 08 Oct 2010 10:22:34 +0200 Message-ID: <87d3rl5c1h.fsf@basil.nowhere.org> References: <1286515292-15882-1-git-send-email-david@fromorbit.com> <1286515292-15882-16-git-send-email-david@fromorbit.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org To: Dave Chinner Return-path: In-Reply-To: <1286515292-15882-16-git-send-email-david@fromorbit.com> (Dave Chinner's message of "Fri, 8 Oct 2010 16:21:29 +1100") Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org Dave Chinner writes: > From: Eric Dumazet > > 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). This doesn't help for Unix disk file systems, so not fully sure why you need it for XFS. But looks reasonable, although it would be better to simply fix sockets/pipes/etc. to not allocate an inode numbers. Acked-by: Andi Kleen -Andi -- ak@linux.intel.com -- Speaking for myself only.