From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alex Harsanyi Newsgroups: gmane.emacs.devel Subject: Fwd: w32-pipe-read-delay (was: vc-dir operation is very slow on large git repositories in Emacs 26.1) Date: Sat, 23 Jun 2018 21:30:46 +0800 Message-ID: References: <83k1qtsbgi.fsf@gnu.org> <83zhzoqkgv.fsf@gnu.org> <83efgzqjv5.fsf@gnu.org> <83wouqptm6.fsf@gnu.org> <83k1qqufwq.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" X-Trace: blaine.gmane.org 1529760564 19556 195.159.176.226 (23 Jun 2018 13:29:24 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 23 Jun 2018 13:29:24 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jun 23 15:29:19 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fWibP-00051N-1R for ged-emacs-devel@m.gmane.org; Sat, 23 Jun 2018 15:29:19 +0200 Original-Received: from localhost ([::1]:38526 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fWidW-0005eS-8Y for ged-emacs-devel@m.gmane.org; Sat, 23 Jun 2018 09:31:30 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36332) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fWicq-0005cA-H6 for emacs-devel@gnu.org; Sat, 23 Jun 2018 09:30:49 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fWicp-0007oc-JC for emacs-devel@gnu.org; Sat, 23 Jun 2018 09:30:48 -0400 Original-Received: from mail-it0-x234.google.com ([2607:f8b0:4001:c0b::234]:54107) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fWicp-0007o1-Cg for emacs-devel@gnu.org; Sat, 23 Jun 2018 09:30:47 -0400 Original-Received: by mail-it0-x234.google.com with SMTP id a195-v6so6519509itd.3 for ; Sat, 23 Jun 2018 06:30:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=ME0DrmEnBjhoES98KSTvaBCUcnSeem0XUw0qMIWGUV8=; b=Qr9lZhO0e77U0mowi63046sPypT/UE+uKOhgl6zP3NMuZe+B/q42xnKYOmtZd2z2SJ mnAJAq2MVIFbt/BBWLthpVk4L7nEdIB2RY7+GHmUvz/1s6JLkbgbyJcjYRDEIo3WV3mn n3o3m7cc1Qm9BlZmp2o6vRB0MJQxQ25o9CYSdlC9K/aBGEhSYOjhPRMp4aygLKt7k6Lv Jm2pxpvDuHQbT8nzcyiHgU0M88//85esOs3Ly5jS6YWCodTJY6Lw6HFsfS6MQ2oUv60u +AT44DUZM3rXEFZG5hg2ESzCc6yOWhScV1Ac7NGxr2uGTdS4WrXyP33o4q4Ppok0NCrZ awkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=ME0DrmEnBjhoES98KSTvaBCUcnSeem0XUw0qMIWGUV8=; b=kRDm+jU3wveqPw2tQBVh15lG1Xo4BiaDlV9rrx5VOQIlPyaYDWB1A+lIxk+iOV6bvh nVR9JaVptkOORA3tNB69GwLJAgJV41tv5O4zZBjoVIcK7fTDWr/YnXMcJvUtq/fAXNKQ 1rUK5Or26P/SfQWWgTjB2SDr0qobi233BSpynyRc1PwuhYa8dQXNRM6DlgBlezaejRtS iEVeH0OPlYgG7fdmw6MeVbMewoFyTgofPTL83tlOX+oDI7FHn15JAr6q0+NB9fdZXq96 HB36fGvsggmLTE2KZl2gk2+ZGbJnEEoxuej7Jg063SbfFJGAvm97qo4WbLuO6XD3oS1u 3nFw== X-Gm-Message-State: APt69E2buAvs0WpXKen6n5a7TOv/I+FxDsDtPZG5LPxB9e+xIItn3Ig1 5rrWd3EjMGIjrdTda4MbzUR367MEds7gM5oa6nJokg== X-Google-Smtp-Source: AAOMgpfsFsOATqavp1n0lst4qoivOypimCH6ao/+gUptlnwgXoVOuW5ZyZHjL5PZOOR5vIWEzgxD+GYC2LKo7uYWYlw= X-Received: by 2002:a24:fd0b:: with SMTP id m11-v6mr4499553ith.54.1529760646453; Sat, 23 Jun 2018 06:30:46 -0700 (PDT) Original-Received: by 2002:a6b:4514:0:0:0:0:0 with HTTP; Sat, 23 Jun 2018 06:30:46 -0700 (PDT) In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c0b::234 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:226623 Archived-At: On Sat, Jun 23, 2018 at 3:21 PM, Eli Zaretskii wrote: > (I'm surprised that this variable had such a profound effect with > Git's ls-files, but maybe that has something to do with the MSYS > components in Git on Windows.) > I don't think this has anything to do with Git or MSYS: I wrote a C++ program to output 1 Mb of data (similar to the perl program I wrote earlier) and I compiled this using Visual Studio, to get a native windows console application. I than set w32-pipe-buffer-size to 0 and experimented with various settings for the w32-pipe-read-delay, using the `time-process` function (see my previous email). Here are the results: * when w32-pipe-read-delay is 50 milliseconds, it takes 13.2 seconds to read 1 Mb of piped data from the C++ executable. * when it is 25 milliseconds, it takes 6.8 secons to read the same data * when it is 12 milliseconds, it takes 3.47 seconds to read the same data * when it is 0, it takes 0.13 seconds Increasing w32-pipe-buffer-size had no effect on the speed -- I know I said in a previous email that it had an effect, but I only tried to increase it after dropping w32-pipe-read-delay to 0 and tried it once -- sometimes the time drops further from 0.13 to 0.8 seconds, but this seems random -- at this speed, probably other factors, such as process startup, have an effect on the read speed. On Monday, I will test it against my work repository with 50000 files, and will report back on that. Alex.