On Thu, 14 Aug 2008 15:11:26 -0400 Trond Myklebust <trond.myklebust@xxxxxxxxxx> wrote: > On Thu, 2008-08-14 at 14:52 -0400, Jeff Layton wrote: > > 1) do what I did here (individual kmalloc for each raparm) > > > > 2) do an allocation of an raparms array for each hash bucket, but when > > we get to larger thread counts, these will still require multi-page > > allocations: > > > > 8192 threads * 2 / 16 buckets * 72 bytes = 73728 byte allocation > > > > 3) declare a separate slabcache for this and allocate each raparm > > individually from that > > > > ...#3 might be reasonable, but we could end up wasting even more memory > > that way when we only have a few threads. Tough call... > > How about > 4) Set an upper cap on the size of the raparm array > > Readahead is only useful in moderation. You don't want to reach a > situation where the various threads' readahead activities start causing > thrashing... > That sounds like it would be a good idea in conjunction with this patch. What would be a reasonable upper limit? -- Jeff Layton <jlayton@xxxxxxxxxx> -- To unsubscribe from this list: send the line "unsubscribe linux-nfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html