Re: Question about list_sort() RCU version.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/16/20 1:24 PM, Mathieu Desnoyers wrote:
> ----- On Jun 16, 2020, at 4:17 PM, Chaitanya Kulkarni Chaitanya.Kulkarni@xxxxxxx wrote:
> 
>> Hi RCU maintainers and experts,
>>
>> I'm working on a linux kernel upstream project which is in the tree.
>> With the POC I can already see that significant performance improvement
>> with RCU in the fast path which are replacing rw semaphore, but not
>> having list_sort() rcu variant is blocking the developement and getting
>> code upstream.
> 
> Why do you need list_sort() ? Is there any way you could simply insert your
> new elements into the list in already-sorted order ? This would ensure that
> the list is always in a sorted state, which I suspect will be expected by
> RCU readers.
> 
> Thanks,
> 
> Mathieu
> 

It is not expected to be in the order by the readers in this case.

For the list to be populated in sorted order it needs to be traversed 
every time in the fast-path which is costly based on the current design,
so we add it to the tail and sort it later in the work-queue context 
when it is actually needed after we complete the scan. The sorting also
takes care of the stale entries. (kind of entangled).

Changing the design is always the last options, I'm trying to port
the code without having to do that so future users also can user the
RCU list_sort() version, unless having this absolutely not makes any
sense.


> 
>>
>> I was not able to find the such helper implemented for the RCU flavor of
>> list.
>>
>> Can someone provide information about :-
>>
>> 1. Is there any plan to have list_sort_rcu() ? if so when can we expect
>>     that ? (Also how can I help ?)
>>
>> 2. In case there is no plan what are design considerations if someone
>>     wants to implement the code and submit it upstream ?
>>     (Also how can I help here ?





[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux