Received: by 2002:ab2:6c55:0:b0:1fd:c486:4f03 with SMTP id v21csp648461lqp; Wed, 12 Jun 2024 11:51:03 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXE4bz4VPKT0z5cEx6QEeZJwFXvZtz0QRrw0LwFK49vkwCpR5XueL2vaaUpRec/RBVq/KmiVbF86gjzX0XQKEuMERXFJ9Fj+q73CX4uhQ== X-Google-Smtp-Source: AGHT+IECmwMrOdfFtPXhhgVx9xYiliO9SPfXQsJ/aaBeAdBqpDgZxh1Asqs7yO7XdtzZuiCnljaA X-Received: by 2002:a17:902:d506:b0:1f4:b7ff:ac41 with SMTP id d9443c01a7336-1f83b601677mr34990305ad.36.1718218263605; Wed, 12 Jun 2024 11:51:03 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718218263; cv=pass; d=google.com; s=arc-20160816; b=J9nrK74CCw0ljPsqBtxlUjH6UeqWloTLs+T2QABASTmYZxDgC2527ZJnjXEUk2z0OW f98fMjoTzOZXNTrvvrOzs+LkVCgseJ8N0pFkFa+NP0AobC67aqhCVAgkt3IIV3P3BKac neKuiQYp5HYX4MGs2KYQs40sxrseqBO/JpEQMrEoqFjM9Y0ds/+WPuuty6hDiawSxkJj edYKDyOHqE8b58behHHWVluIem1SvcxmClABOrWlNeBNmLUXHnkzQTByYWBI0MnYU94B ULOtKklv1ju4UxvS1OgsJ+74qrv12jH3VN9moYfCloNQC5jbKAEz7tD6yVJVk7/MFLo7 3Ikg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :reply-to:message-id:subject:cc:to:from:date:dkim-signature :dkim-signature:dkim-signature:dkim-signature; bh=0cer0If1HAzS1rq/ObJK8fArocZBEgcs+4FYJpm4dg4=; fh=+TKxS4K8NmZuYUAnuSZ8cnUEYGwhEUkXrWXQ/n0wAqM=; b=l0hOvRh9S8s/g53te586d6jVjfwUfa01Ggxx6wa+wOY2X2ea8MSeS3r81KtAKnpF0x 9lEVhximbYFVg4aoIdhLOOx4xkQYHbTdTg7/ThJc8xuzhuFlscmMfXKadoeG7+r8UeI+ 002yaYJnKNEbv1q8qSW/m2/Lv5XcpxoT6ZuYoi4e+vVHDGXM1QIFUhysVSJfxd4jl/u0 X51Y6cCF6zvJlu9ArrNWdTJ+SVck5m2exbKJffxczS5Am/d2oIA6vDiqHP5BprHtnbjV +6vfb9K8iJ+kGOLudn6IGhm6y2xykv+I9ie9pHxBqYoQwmqaT6PRZwCjz6WMxdMMtjht L1FA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=dZxwggmy; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=oDgu+xu4; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; arc=pass (i=1 spf=pass spfdomain=suse.cz dkim=pass dkdomain=suse.cz dkim=pass dkdomain=suse.cz); spf=pass (google.com: domain of linux-kernel+bounces-212087-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-212087-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id d9443c01a7336-1f70ec6950esi66076035ad.609.2024.06.12.11.51.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jun 2024 11:51:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-212087-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=dZxwggmy; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=oDgu+xu4; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; arc=pass (i=1 spf=pass spfdomain=suse.cz dkim=pass dkdomain=suse.cz dkim=pass dkdomain=suse.cz); spf=pass (google.com: domain of linux-kernel+bounces-212087-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-212087-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 2473FB278E6 for ; Wed, 12 Jun 2024 18:35:38 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 408808063B; Wed, 12 Jun 2024 18:33:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b="dZxwggmy"; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b="Fg6SnWWA"; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b="oDgu+xu4"; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b="f7szkrT6" Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2DA7A71747; Wed, 12 Jun 2024 18:33:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.135.223.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718217215; cv=none; b=YXW3kRptNS8WZFwYfyfJiLMLcCbmslQgZzax6yeq5+GN64eSR5EomALRYrxjBk9YHDf5+GQanfo7nAzRl6jjEtmfNZc/i4kkEIjon2MtpQTdtL3GmyQhoQ/r2vt6Dmq2x8ekPv5Y4ljP3EZR0ku25efVMfp6SXmk90wikISqU4k= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718217215; c=relaxed/simple; bh=faZcWAtuhGHaOkTzDVhSBkGucdApEpkt4Q3fVDWYs7Q=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=lrLIz0HCapxulNmByt2sUUREr/PaK2p0YtJXdbbMSKaNDjDRvfVkogMvUSSP12nAsQTKANWmNM9m8KxokQTh5GkeUqBT3V7/YxVIurfJbzakgBZTkDEY5qNtBWFZ3tPGxeRiBNRpuW+BJuI/qm7fnrthy5L92ggteBbZ//LCnjQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz; spf=pass smtp.mailfrom=suse.cz; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b=dZxwggmy; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b=Fg6SnWWA; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b=oDgu+xu4; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b=f7szkrT6; arc=none smtp.client-ip=195.135.223.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.cz Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id DB0075C59B; Wed, 12 Jun 2024 18:33:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1718217211; h=from:from:reply-to: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=0cer0If1HAzS1rq/ObJK8fArocZBEgcs+4FYJpm4dg4=; b=dZxwggmyjmFUy63iHNTvDyRLbG13qNf4s0ubon5OSgaFlFrnnr65wXuX/aIcq/m4xQVsbj UVtqeUGup4wgn7qvntKEYiYPHH92C685yhCiow+6SqK/xJJ86KfB7iKWctXX+WPB4Djdkl sqKpCSO3gvDhN2bn7jCMWgJ2tYRG24A= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1718217211; h=from:from:reply-to: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=0cer0If1HAzS1rq/ObJK8fArocZBEgcs+4FYJpm4dg4=; b=Fg6SnWWADfIITUHwLRladDGkpicCEqjnlG60sfSfVBFjq7f1pImTaSsdE0dshb49H3SxgW BwRrputQOBTXDeBw== Authentication-Results: smtp-out2.suse.de; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b=oDgu+xu4; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b=f7szkrT6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1718217210; h=from:from:reply-to: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=0cer0If1HAzS1rq/ObJK8fArocZBEgcs+4FYJpm4dg4=; b=oDgu+xu4+2JNKwuihxt4l0qvk2awI+eQgEE6QHvqwyMGCAW7uxl58ipfD1d3D0YIcqn+d5 a0cCIPL8xmbIM7rzSwKNzdmyhRC0geoT7c0lGu0ch1qACjjHhIwZHTBwpzt7/PjxgELpUb NIe4g1jHsYVbsVoDexHfc2B/G8/JiFY= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1718217210; h=from:from:reply-to: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=0cer0If1HAzS1rq/ObJK8fArocZBEgcs+4FYJpm4dg4=; b=f7szkrT6v/B8HF1uMBpeASFn1Dm8YWMWkyGOQL4F/bNB1A6MkMevBe7orRRK06jFhDBeaL 3bBRX15oFPuflwDQ== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id BD09B1372E; Wed, 12 Jun 2024 18:33:30 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id +xn3LfrpaWZRDwAAD6G6ig (envelope-from ); Wed, 12 Jun 2024 18:33:30 +0000 Date: Wed, 12 Jun 2024 20:33:29 +0200 From: David Sterba To: Mateusz Guzik Cc: brauner@kernel.org, viro@zeniv.linux.org.uk, jack@suse.cz, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-btrfs@vger.kernel.org, josef@toxicpanda.com, hch@infradead.org Subject: Re: [PATCH v4 2/2] btrfs: use iget5_locked_rcu Message-ID: <20240612183329.GI18508@twin.jikos.cz> Reply-To: dsterba@suse.cz References: <20240611173824.535995-1-mjguzik@gmail.com> <20240611173824.535995-3-mjguzik@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240611173824.535995-3-mjguzik@gmail.com> User-Agent: Mutt/1.5.23.1-rc1 (2014-03-12) X-Spamd-Result: default: False [-4.21 / 50.00]; BAYES_HAM(-3.00)[99.99%]; NEURAL_HAM_LONG(-1.00)[-1.000]; HAS_REPLYTO(0.30)[dsterba@suse.cz]; R_DKIM_ALLOW(-0.20)[suse.cz:s=susede2_rsa,suse.cz:s=susede2_ed25519]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MIME_GOOD(-0.10)[text/plain]; MX_GOOD(-0.01)[]; FREEMAIL_TO(0.00)[gmail.com]; FUZZY_BLOCKED(0.00)[rspamd.com]; ARC_NA(0.00)[]; TO_DN_SOME(0.00)[]; RCVD_TLS_ALL(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_VIA_SMTP_AUTH(0.00)[]; RCPT_COUNT_SEVEN(0.00)[9]; FREEMAIL_ENVRCPT(0.00)[gmail.com]; DNSWL_BLOCKED(0.00)[2a07:de40:b281:106:10:150:64:167:received]; FROM_EQ_ENVFROM(0.00)[]; FROM_HAS_DN(0.00)[]; DKIM_SIGNED(0.00)[suse.cz:s=susede2_rsa,suse.cz:s=susede2_ed25519]; REPLYTO_ADDR_EQ_FROM(0.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email,imap1.dmz-prg2.suse.org:helo,imap1.dmz-prg2.suse.org:rdns]; RCVD_COUNT_TWO(0.00)[2]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DKIM_TRACE(0.00)[suse.cz:+] X-Rspamd-Action: no action X-Rspamd-Server: rspamd2.dmz-prg2.suse.org X-Rspamd-Queue-Id: DB0075C59B X-Spam-Flag: NO X-Spam-Score: -4.21 X-Spam-Level: On Tue, Jun 11, 2024 at 07:38:23PM +0200, Mateusz Guzik wrote: > With 20 threads each walking a dedicated 1000 dirs * 1000 files > directory tree to stat(2) on a 32 core + 24GB ram vm: > > before: 3.54s user 892.30s system 1966% cpu 45.549 total > after: 3.28s user 738.66s system 1955% cpu 37.932 total (-16.7%) > > Benchmark can be found here: https://people.freebsd.org/~mjg/fstree.tgz > > Reviewed-by: Josef Bacik > Signed-off-by: Mateusz Guzik Acked-by: David Sterba