Re: [RFC] replace revoke hash table with rhashtable

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

 



On Aug 31, 2021, at 8:49 AM, Alex Zhuravlev <azhuravlev@xxxxxxxxxxxxx> wrote:
> 
> Hi,
> 
> Not so long ago we noticed that journal replay can take quite a lot (hours)
> in cases where many journaled blocks were freed during a short period.

It may be worthwhile to mention this was a case with a 4GB journal size.

> I benchmarked hash table used by revoke code, basically it’s lookup+insert
> like jbd2 does at replay:
> 
> 1048576 records - 95 seconds
> 2097152 records - 580 seconds
> 
> Then I benchmarked rhashtable:
> 1048576 records - 2 seconds
> 2097152 records - 3 seconds
> 4194304 records - 7 seconds
> 
> So, here is a patch replacing existing fixed-size hash table with rhashtable, please have a look.
> 
> Thanks, Alex

Alex,
the patch looks good from both a performance standpoint, as well as
a good reduction in lines (and possibly memory, for the cases where
there are fewer entries in the hash than the static table size).

I did notice some lines are using 8-space indents instead of tabs.
That can be fixed if there are any other comments, and you resubmit
without [RFC].

Cheers, Andreas





Attachment: signature.asc
Description: Message signed with OpenPGP


[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux