From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#71094: [PATCH] Prefer to run find and grep in parallel in rgrep Date: Wed, 22 May 2024 15:34:06 +0300 Message-ID: <8aedd0ed-58fe-4ac7-98d6-950be2d4700b@gutov.dev> References: <86ttiq6or8.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="29781"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird Cc: rgm@gnu.org, 71094@debbugs.gnu.org To: Eli Zaretskii , Spencer Baugh Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed May 22 14:35:24 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1s9lBj-0007Sz-Au for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 22 May 2024 14:35:23 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s9lBM-000625-1S; Wed, 22 May 2024 08:35:00 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s9lBJ-00061Y-Hb for bug-gnu-emacs@gnu.org; Wed, 22 May 2024 08:34:57 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s9lBJ-0006K0-8T for bug-gnu-emacs@gnu.org; Wed, 22 May 2024 08:34:57 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s9lBN-0002Ei-VC for bug-gnu-emacs@gnu.org; Wed, 22 May 2024 08:35:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 22 May 2024 12:35:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71094 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 71094-submit@debbugs.gnu.org id=B71094.17163812658575 (code B ref 71094); Wed, 22 May 2024 12:35:01 +0000 Original-Received: (at 71094) by debbugs.gnu.org; 22 May 2024 12:34:25 +0000 Original-Received: from localhost ([127.0.0.1]:55694 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s9lAm-0002EF-S5 for submit@debbugs.gnu.org; Wed, 22 May 2024 08:34:25 -0400 Original-Received: from fhigh6-smtp.messagingengine.com ([103.168.172.157]:45049) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s9lAk-0002E9-Da for 71094@debbugs.gnu.org; Wed, 22 May 2024 08:34:23 -0400 Original-Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailfhigh.nyi.internal (Postfix) with ESMTP id 65BCF1140186; Wed, 22 May 2024 08:34:10 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Wed, 22 May 2024 08:34:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm2; t=1716381250; x=1716467650; bh=Bw2pw+KKsuQqZ/gh4mqwA+QH/qC0nRxk9EDXIicx97I=; b= rwqbZfFeVxxbaQLXDb3y84o+z9CuI/c23sVFNuT/w9hSSLmKMaLaNqLbx3CZxJ9m 3cVY+pvY+9puEPlY5PTJyVDV5lqOPSK+rbrKPFqfoxj7Ubd0ulPYtmGy9MdRhMfC KDtVrZqdCULrqpdKuzGq1ws+j+6SLr0SDo9kXmgTgIDdwXzMuzNsDYP2xfvbVB25 PwvoWfpJ0dN5eJoLpTNBHqpk4YgtK/iYy62qkearMjZhBkliH42HU/XkjMgXXw5R r0RbvW5eNHYP+51Sd1u5uONEGzV0iFRe+o2I9fMcgRgQeyrESMMkhFOu6zb8Rqd0 zdhcf+jHBC+pXL83ydu/Pw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1716381250; x= 1716467650; bh=Bw2pw+KKsuQqZ/gh4mqwA+QH/qC0nRxk9EDXIicx97I=; b=m UOLMuTfJcITXaw4k2z+GZ9xKM8SKuimqcrFwdsasBcYtO6j0WLzSQcr1gOfsFbX8 96eLW7VEOJyWtN/B9b5TEpayAUByA3AHOBOvrE8JSqhnvDObS/AJFPRKxXdAcASF he35f02EAXIyX0aR0INkmBdWCNG0hJvc9fBCpLNIRj7Mvx2hM10Pp+Ntj7KsqOKq F/7hEUSKYhOsiG3LFFdZKf4jVjD5ZV9/bk0xx3Jy/zrkTGLoSSos7UA8rbpkbQeo QP3nPghKTvvElLrMtGTSreXzVsWKaoThLa9vKGtcesSHEUItC/ATpNXptlMjGtrf wxdut2IzUmBPXOTbZ6zGA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvdeigedguddtucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepkfffgggfuffvvehfhfgjtgfgsehtjeertddtvdejnecuhfhrohhmpeffmhhi thhrhicuifhuthhovhcuoegumhhithhrhiesghhuthhovhdruggvvheqnecuggftrfgrth htvghrnhepteduleejgeehtefgheegjeekueehvdevieekueeftddvtdevfefhvdevgedu jeehnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepug hmihhtrhihsehguhhtohhvrdguvghv X-ME-Proxy: Feedback-ID: i0e71465a:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 22 May 2024 08:34:09 -0400 (EDT) Content-Language: en-US In-Reply-To: <86ttiq6or8.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:285608 Archived-At: On 22/05/2024 14:59, Eli Zaretskii wrote: > With how many files did you measure the 40% speedup? Can you show the > performance with much fewer and much more files than what you used? FWIW my test indicated that for a smaller project (such as Emacs) the difference is fairly small - the new code is slightly better or the same. The directory where I saw significant improvement has 300K files. > I > suspect that the effect depends on that. (It also depends on the > system limit on the number of files and the length of the command line > that xargs can use.) The argument about 'find' waiting is no longer > relevant with 'exec-plus', since in most cases there will be just one > invocation of 'grep'. If there's just one invocation, wouldn't that mean that it will happen at the end of the full directory scan? Rather than in parallel.