lkml.org 
[lkml]   [2011]   [May]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch V3] percpu_counter: scalability works
Hello, Eric, Shaohua.

On Tue, May 17, 2011 at 11:01:01AM +0200, Eric Dumazet wrote:
> Just convince him that percpu_counter by itself cannot bring a max
> deviation guarantee. No percpu_counter user cares at all. If they do,
> then percpu_counter choice for their implementation is probably wrong.
>
> [ We dont provide yet a percpu_counter_add_return() function ]

I haven't gone through this thread yet but will do so later today, but
let me clarify the whole deviation thing.

1. I don't care reasonable (can't think of a better word at the
moment) level of deviation. Under high level of concurrency, the
exact value isn't even well defined - nobody can tell operations
happened in what order anyway.

2. But I _do_ object to _sum() has the possibility of deviating by
multiples of @batch even with very low level of activity.

I'm completely fine with #1. I'm not that crazy but I don't really
want to take #2 - that makes the whole _sum() interface almost
pointless. Also, I don't want to add big honking lglock to just avoid
#2 unless it can be shown that the same effect can't be achieved in
saner manner and I'm highly skeptical that would happen.

Thank you.

--
tejun


\
 
 \ /
  Last update: 2011-05-17 11:13    [W:0.160 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site