From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ergus via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#49264: 28.0.50; project.el+tramp performance issue Date: Thu, 19 Aug 2021 05:08:33 +0200 Message-ID: <20210819030833.b5xejdgjy2avnq2e@Ergus> References: <20210726165610.7pjiyuz4vtxuhgq7.ref@Ergus> <20210726165610.7pjiyuz4vtxuhgq7@Ergus> <14a3d5a3-33bf-cc82-d144-7302629aa33b@yandex.ru> <73afb142-38f4-9e0e-ee46-14ff70db5b72@yandex.ru> <20210817004551.25qheo6v2gfys3ie@Ergus> Reply-To: Ergus Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27324"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 49264@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 19 05:10:14 2021 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 1mGYRZ-0006xo-D2 for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 19 Aug 2021 05:10:13 +0200 Original-Received: from localhost ([::1]:32776 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mGYRX-0005b0-GV for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 18 Aug 2021 23:10:11 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56310) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mGYRO-0005Zg-Gg for bug-gnu-emacs@gnu.org; Wed, 18 Aug 2021 23:10:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:46334) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mGYRO-0002tV-9y for bug-gnu-emacs@gnu.org; Wed, 18 Aug 2021 23:10:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mGYRO-00033r-1s for bug-gnu-emacs@gnu.org; Wed, 18 Aug 2021 23:10:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Ergus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 19 Aug 2021 03:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49264 X-GNU-PR-Package: emacs Original-Received: via spool by 49264-submit@debbugs.gnu.org id=B49264.162934255311692 (code B ref 49264); Thu, 19 Aug 2021 03:10:02 +0000 Original-Received: (at 49264) by debbugs.gnu.org; 19 Aug 2021 03:09:13 +0000 Original-Received: from localhost ([127.0.0.1]:57878 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mGYQa-00032W-Rc for submit@debbugs.gnu.org; Wed, 18 Aug 2021 23:09:13 -0400 Original-Received: from sonic313-15.consmr.mail.bf2.yahoo.com ([74.6.133.125]:33388) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mGYQU-00031s-1k for 49264@debbugs.gnu.org; Wed, 18 Aug 2021 23:09:11 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048; t=1629342539; bh=vSPcNxQhDGZ/JGO2hGm89c5fp7r3Q9iDeX4/LuYs9IM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From:Subject:Reply-To; b=RiKUqfP/CzUQ8uLFC38I+l8FzOSIf2epwFpCEMXe477uiz68TMzOiCSKaDyE9ZPM/M6+eI73ViGuX6DRb7xMPoSknmnsmAdFmrT3jLDnkEmvrFk62qflLcw4zH1nfjl+05iEFCRIrdSgDF0zwOY5g8vHK/gjEQoYxZT6bg+aD8ueoJgtP8J/kuSs5KBahj/tY//4usI7N+xfZB3nW9IDilK6H7QZX/6673CR/G5ZxKNwmG60GXVPuY7GxqJQDaMzHAbFfb7qpC/mMPORiSZVv4UcEqKlFBb/tNh6RdSt5RNg87oerln4vRTKEVJ11YLcoY7v6s33lW7IPyPXdHrC5Q== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1629342539; bh=nWqc1K816kPqYbp+bwRmT6Mi6AYXcQPn/3U5RRKhFqW=; h=X-Sonic-MF:Date:From:To:Subject:From:Subject; b=kek21LOfpVLCIB64ILpr+HtFQF0lrJXytr1QWUvXYMtnIjDpTW4ew3KwvYbR2bbK/QSz5oTTDlGYjD/FjY9JDlf6HBIqtdvfhoCQ9FV4XioymTjtkb/XxHhbZBwIMtdSHlNpMe4mKLKMVJpqze4EAi8mAVxkFl7JtQKFTBbVPSEPbSkjlF605U5TB2fvO+AgwHFC2EN80XB+QKuOlCSGocLPbgpkFm5y720iX4+7WdPJNotBV4hdAEoWqPxScQ+00k8WTIXbv7vEaDF9zClBdMkLMx681zeYQOOcVwaSko4JTHpEQTUvXcsahsIu/q1JUoS8WZPrW2vNhVu+0FD9HA== X-YMail-OSG: q.Ot9cIVM1meBs_BgWSl1il91GUzUVNLD5tterWGFY9eOYayAxxd6xPmK1Y4bxx ZR02nVAaEN7A_tZ09nO48h3Ji55lwyBW7oz221HgaEG4zCvYNeqOJzdGnzSF9aXCu54j7NuzCshg nPNjs0MLT1DkC7yjBvZRtge_Qax7O9ymSQ4jRGoMxBVsJYSWTAATt0ahIOcRDL42P.YY7XDlZWwh ukq8IS40T3HMwXe1yJY5sjrCQcu9BIwuiRtZX81ie30lakERQudjg.2DIBpeDupFM5lmZyIXaZN1 pERNRlZYJpXxTPsMYAABgtCqEGuzN1Z1QCtk_skwc3OVuM6GnUrAVaaFpUMTLg2RyA1IqcD.qiEB aknWwx9p41urg4Mm4nGVw.bXLm8ZEZI2j4MTOtjO19OjSvvh9l6Fh6wxuuLZ3fguXxx.fZL8a.gF jMdZqawJ1bcU.8xTvCNbl69Qk9pjbdjIgjrZiAXoScSQNIkbwtH8bAbYpax0EGoGxZeJYOkwFZBx iLzt9ci6ZDz00BhoxlKsy0W_96sQMRh8dpGxmwCYcVswWuK1tmLhcLyQGRM_BgRrp2qwVaNcu5ev kB37R_9Y6.vJBYtzNU7.coafb26w..ifXZXF4F4rJZkaZNRx6x6f1z30vtJhzvmhnb8gknpJqQkQ 7dIQkv7IjR_aDJSTl50uJgbrd9W0X9vsWtTCX13WjESaGLapxKZmRprORrgh7O3gMvGXAinEhv6E fETYxDSRq78KRKeYrM210x1Kj_pDL9hpE.gv2MkTY8JEcGRZKG0eQOTiRGy_qRBsY6znRWjSysW3 ZPWIq7tWClY3hfQBInx5HqcabK7_ScI8mUpwkXfI9i X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic313.consmr.mail.bf2.yahoo.com with HTTP; Thu, 19 Aug 2021 03:08:59 +0000 Original-Received: by kubenode527.mail-prod1.omega.ir2.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID f3336c55d69bb0c628feb764f49b83b5; Thu, 19 Aug 2021 03:08:56 +0000 (UTC) Content-Disposition: inline In-Reply-To: X-Mailer: WebService/1.1.18850 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol 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" Xref: news.gmane.io gmane.emacs.bugs:212192 Archived-At: On Thu, Aug 19, 2021 at 04:19:20AM +0300, Dmitry Gutov wrote: >Hi Ergus, > >On 17.08.2021 03:45, Ergus wrote: > >>I made a manual fast profiling and I see that most of the time in >>project-buffers actually goes to tramp-sh-file-name-handler. >> >> �������� 207� 42%�������� - project-buffers >> �������� 207� 42%��������� - apply >> �������� 207� 42%���������� - # >> �������� 200� 40%����������� - file-in-directory-p >> �������� 200� 40%������������ - tramp-file-name-handler >> �������� 197� 40%������������� - apply >> �������� 197� 40%�������������� - tramp-sh-file-name-handler >> �������� 197� 40%��������������� - tramp-handle-file-in-directory-p >> �������� 183� 37%���������������� - tramp-run-real-handler >> �������� 183� 37%����������������� - file-in-directory-p >> �������� 124� 25%������������������ - file-equal-p >> �������� 124� 25%������������������� - tramp-file-name-handler >> �������� 121� 24%�������������������� - apply >> �������� 121� 24%��������������������� - tramp-sh-file-name-handler >> �������� 121� 24%���������������������� - tramp-handle-file-equal-p >> ��������� 85� 17%����������������������� - tramp-run-real-handler >> ��������� 85� 17%������������������������ - file-equal-p >> ��������� 52� 10%������������������������� - file-truename >> ��������� 52� 10%�������������������������� - tramp-file-name-handler >> ��������� 41�� 8%��������������������������� - apply >> ��������� 41�� 8%���������������������������� - tramp-sh-file-name-handler >> ��������� 41�� 8%����������������������������� - >>tramp-sh-handle-file-truename >> ��������� 28�� 5%������������������������������ + file-remote-p >> ��������� 10�� 2%������������������������������ + file-local-name >> ���������� 3�� 0%������������������������������ + file-name-as-directory >> >>It goes specifically to file-in-directory-p as you said. So maybe the >>improvement there may be also desirable if the difference after the >>optimization can reduce the time for file-in-directory-p (or the caller) >>at least to the half. > >Thanks for testing. > >Try the attached new version please. It should eliminate that >particular bottleneck. Hi: It feels better now. There is still a small delay, but that is normal working with tramp. I will try it a bit more tomorrow; but the first impression is that this solves the issue for me. Best, Ergus