Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp3117194ybl; Sun, 26 Jan 2020 19:56:40 -0800 (PST) X-Google-Smtp-Source: APXvYqzltxdOBDjZ9ZzZqv+N+D2uGfJHepwxHDku0PVc7SzEYgujTn8kUeo+TcQfEEJMZYc9DhPO X-Received: by 2002:a9d:6653:: with SMTP id q19mr10674129otm.94.1580097400170; Sun, 26 Jan 2020 19:56:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580097400; cv=none; d=google.com; s=arc-20160816; b=DtP0/TOnCmbNNWUUzEazNzY1a/J9Ufd6EGbCxvQf87PjPUTR/N62TgmhHDXbma53Yq 6cTxb7zYtIwSwzOf7bAV8QEZzCjTDlZrHtMWMtYwdXNyyyibDHRClWnjJvl+iS6yDJEU kd/nOlsFWtUSgWA83KTB9rnmCdBqlZmvNQHEpnK1yl+A//9K+DKErxuBM809dl13liz3 vcxMKSFmsxTlpog61+AjMZ0WTkkzIPi5w+pS9jD1qp4anSzCd/lkcfYqAGxaCTNj9Des YhOiNsGmW89mFGJh9zNzmHO+dxCN6rc20hnoy7Z6+qkv/DHXqvLe7RoI346XuiIxBhRQ yovA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=WrmKenp7pqAC3pQLWZoeTLoJi7tcW1z0Ab4tlNOJjA0=; b=HML+F77YYxEZj1MfMmVt1Kme+E45UHSR+JtoF3/kjyLYya1CtDcU8rDIfo4ky9CDmJ 2q75QiQ10T4vCuYo44cONrWTNCWoNT4hiu1+nXxVLH0BeKVkR+yaiH6WVsWpCgD4+UiM +F2quRo3lyp3fmWyoVj1B0Nh/Zi5XcBYHgikVzQzbim1x2L13iBAhgfDR9Fon2gYAFwl 5W4zIrypozbCPIxCnqQCrB4RN5SofTmOrwiGq3EEnvJHCxICUBzNhOYjrPYXLQ9bThgG Th24vefyRJ8UcdU9acItggZ3UgCghoD13/LIcyBmfVZVjm3wkFpffm5E6MWuPEIIBV3u yOnA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 17si6648894otv.149.2020.01.26.19.56.13; Sun, 26 Jan 2020 19:56:40 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726670AbgA0Dzp (ORCPT + 99 others); Sun, 26 Jan 2020 22:55:45 -0500 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:51888 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726545AbgA0Dzp (ORCPT ); Sun, 26 Jan 2020 22:55:45 -0500 Received: from callcc.thunk.org ([67.142.235.252]) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 00R3tRJT005833 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Sun, 26 Jan 2020 22:55:37 -0500 Received: by callcc.thunk.org (Postfix, from userid 15806) id 9F4D7420324; Sun, 26 Jan 2020 21:56:01 -0500 (EST) Date: Sun, 26 Jan 2020 21:56:01 -0500 From: "Theodore Y. Ts'o" To: Li Dongyang Cc: "linux-ext4@vger.kernel.org" , "adilger@dilger.ca" Subject: Re: [PATCH v3 1/5] libext2fs: optimize ext2fs_convert_subcluster_bitmap() Message-ID: <20200127025601.GA115399@mit.edu> References: <20191120043448.249988-1-dongyangli@ddn.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191120043448.249988-1-dongyangli@ddn.com> Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Wed, Nov 20, 2019 at 04:35:21AM +0000, Li Dongyang wrote: > For a bigalloc filesystem, converting the block bitmap from blocks > to chunks in ext2fs_convert_subcluster_bitmap() can take a long time > when the device is huge, because we test the bitmap > bit-by-bit using ext2fs_test_block_bitmap2(). > Use ext2fs_find_first_set_block_bitmap2() which is more efficient > for mke2fs when the fs is mostly empty. > > e2fsck can also benefit from this during pass1 block scanning. > > Time taken for "mke2fs -O bigalloc,extent -C 131072 -b 4096" on a 1PB > device: > > without patch: > real 27m49.457s > user 21m36.474s > sys 6m9.514s > > with patch: > real 6m31.908s > user 0m1.806s > sys 6m29.697s > > Signed-off-by: Li Dongyang > Reviewed-by: Andreas Dilger Applied, thanks. - Ted