* Uladzislau Rezki <[email protected]> [250909 05:08]: ...
> > > > - call_rcu() can be slow, therefore we do not use it in the kvfree_rcu(). > > > > If call_rcu() is called once per 32 kfree_rcu() filling up the rcu sheaf, is > > it still too slow? > > > You do not know where in a queue this callback lands, in the beginning, > in the end, etc. It is part of generic list which is processed one by > one. It can contain thousands of callbacks. How does this differ from kvfree_rcu()? Surely if you have enough calls to kvfree_rcu(), you will end up with a large list of frees before the end of a grace period? Our placement in the freeing order would still be dependent on what else is using the infrastructure in the same grace period, right? How is kvfree_rcu() affected by rcu callback offloading to a specific cpu and rcu expedite? Often these two features come into play for certain workloads which are of concern to us. > > If performance is not needed then it is not an issue. But in > kvfree_rcu() we do not use it, because of we want to offload > fast. Today, I free things using call_rcu() and a custom callback so I would think stacking 32 together would make the list shorter, but latency would increase by waiting until there are 32. If we wanted to flush the kvfree_rcu() list, is it done in the same way as the call_rcu() list, or is there a better way? Thanks, Liam

