Re: [PATCH 4/9] e2fsck: reduce memory usage for many directories

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

 



On Thu, Feb 06, 2020 at 06:09:41PM -0700, Andreas Dilger wrote:
> Pack struct dx_dir_info and dx_dirblock_info properly in memory, to
> avoid holes, and fields are not larger than necessary.  This reduces
> the memory needed for each hashed dir, according to pahole(1) from:
> 
>     struct dx_dir_info {
>         /* size: 32, cachelines: 1, members: 6 */
>         /* sum members: 26, holes: 1, sum holes: 2 */
>         /* padding: 4 */
>     };
>     struct dx_dirblock_info {
>         /* size: 56, cachelines: 1, members: 9 */
>         /* sum members: 48, holes: 2, sum holes: 8 */
>         /* last cacheline: 56 bytes */
>     };
> 
> to 8 bytes less for each directory and directory block, and leaves
> space for future use if needed (e.g. larger numblocks):
> 
>     struct dx_dir_info {
>         /* size: 24, cachelines: 1, members: 6 */
>         /* sum members: 20, holes: 1, sum holes: 4 */
>         /* bit holes: 1, sum bit holes: 7 bits */
>     };
>     struct dx_dirblock_info {
>         /* size: 48, cachelines: 1, members: 9 */
>     };
> 
> Signed-off-by: Andreas Dilger <adilger@xxxxxxxxxxxxx>
> Lustre-bug-id: https://jira.whamcloud.com/browse/LU-13197

Applied, thanks.

					- Ted



[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