From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id CEB30C38145 for ; Thu, 8 Sep 2022 09:03:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230420AbiIHJD2 (ORCPT ); Thu, 8 Sep 2022 05:03:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34634 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229899AbiIHJD1 (ORCPT ); Thu, 8 Sep 2022 05:03:27 -0400 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2DA99FD23D for ; Thu, 8 Sep 2022 02:03:26 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id D576133E62; Thu, 8 Sep 2022 09:03:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1662627804; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=48LcsDgjIxYPdPBigHvE+EJ2px8jIb3sWmT1t4vPf98=; b=ax/qnY9O2vEVxqdJuizzYUYjQ48kdTK5JLyVzCYI8OQJ1btYD2gHekTFaCf0aqc+UBWmgW epm/B2O3HflAP9HbUc+bs/NiIkzUFYlF8OC3hL0LHp4w2Jlh6+3I9Mvi91dKrG42sSJGHf hvZiL43SIqDJDd1aSIuu+ZLvT6sHDGU= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1662627804; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=48LcsDgjIxYPdPBigHvE+EJ2px8jIb3sWmT1t4vPf98=; b=gVAob4V2LRV8ypoVH2F+ONgAbWSIooJtTAo0If7lbn88/ZwTwQ+d+lHWO9SQvrY/Hi7u7Q YhQWJMqe4wh5UpCw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id BAD5B1322C; Thu, 8 Sep 2022 09:03:24 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id s3uaLdyvGWPjPAAAMHmgww (envelope-from ); Thu, 08 Sep 2022 09:03:24 +0000 Received: by quack3.suse.cz (Postfix, from userid 1000) id F0B23A067E; Thu, 8 Sep 2022 11:03:23 +0200 (CEST) Date: Thu, 8 Sep 2022 11:03:23 +0200 From: Jan Kara To: Ojaswin Mujoo Cc: Jan Kara , Ted Tso , linux-ext4@vger.kernel.org, Thorsten Leemhuis , Stefan Wahren , Andreas Dilger Subject: Re: [PATCH 5/5] ext4: Use buckets for cr 1 block scan instead of rbtree Message-ID: <20220908090323.e4enzh5ahxxw64ic@quack3> References: <20220906150803.375-1-jack@suse.cz> <20220906152920.25584-5-jack@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thu 08-09-22 13:59:58, Ojaswin Mujoo wrote: > Hi Jan, > > On Tue, Sep 06, 2022 at 05:29:11PM +0200, Jan Kara wrote: > > > > ** snip ** > > /* > > * Choose next group by traversing average fragment size tree. Updates *new_cr > Maybe we can change this to "average fragment size list of suitable > order" Right. Fixed. Thanks for catching this. > > - * if cr lvel needs an update. Sets EXT4_MB_SEARCH_NEXT_LINEAR to indicate that > > - * the linear search should continue for one iteration since there's lock > > - * contention on the rb tree lock. > > + * if cr level needs an update. > > */ > > static void ext4_mb_choose_next_group_cr1(struct ext4_allocation_context *ac, > > int *new_cr, ext4_group_t *group, ext4_group_t ngroups) > > { > > struct ext4_sb_info *sbi = EXT4_SB(ac->ac_sb); > > - int avg_fragment_size, best_so_far; > > - struct rb_node *node, *found; > > - struct ext4_group_info *grp; > > Other than that, this patch along with the updated mb_structs_summary > proc file change looks good to me. Thanks for review & testing! Honza -- Jan Kara SUSE Labs, CR