From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.help Subject: Re: vc-git-state very slow, waiting for `git diff-index`, in large repositories Date: Wed, 01 Aug 2012 20:19:10 +0400 Message-ID: <501956FE.50204@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1343837970 30877 80.91.229.3 (1 Aug 2012 16:19:30 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 1 Aug 2012 16:19:30 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: matthewlmcclure@gmail.com Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Aug 01 18:19:30 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Swbdx-0007Au-Av for geh-help-gnu-emacs@m.gmane.org; Wed, 01 Aug 2012 18:19:29 +0200 Original-Received: from localhost ([::1]:43671 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Swbdw-0004QD-Fc for geh-help-gnu-emacs@m.gmane.org; Wed, 01 Aug 2012 12:19:28 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:49999) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Swbdo-0004Pf-Ip for help-gnu-emacs@gnu.org; Wed, 01 Aug 2012 12:19:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Swbdh-0005kH-2R for help-gnu-emacs@gnu.org; Wed, 01 Aug 2012 12:19:20 -0400 Original-Received: from forward1.mail.yandex.net ([77.88.46.6]:51151) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Swbdg-0005ju-M3 for help-gnu-emacs@gnu.org; Wed, 01 Aug 2012 12:19:12 -0400 Original-Received: from smtp3.mail.yandex.net (smtp3.mail.yandex.net [77.88.46.103]) by forward1.mail.yandex.net (Yandex) with ESMTP id E96381240B53; Wed, 1 Aug 2012 20:19:09 +0400 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1343837950; bh=3MkW4knteucGAYghS9KxEqUO9m1ffwyAHPmlV57g13c=; h=Message-ID:Date:From:MIME-Version:To:CC:Subject:Content-Type: Content-Transfer-Encoding; b=oBHCiAZd5O+kp6IiDEHH/z9aLvi40Ubiciw2VVhJXzQ24wAkOVW7KnS/cxbKbeFZg imDKuBl8J1ogKMgUcBLuvbW/HkiuNlafSd2NS9mIrknoFSUN2hGlQLkVbnD93TkNok N5OlmiaovJk18g5Bqxs14mhHV3Yw/M//MJC36N9U= Original-Received: from smtp3.mail.yandex.net (localhost [127.0.0.1]) by smtp3.mail.yandex.net (Yandex) with ESMTP id C5DFF1BA07E6; Wed, 1 Aug 2012 20:19:09 +0400 (MSK) Original-Received: from 98-87.nwlink.spb.ru (98-87.nwlink.spb.ru [178.252.98.87]) by smtp3.mail.yandex.net (nwsmtp/Yandex) with ESMTP id J9JuQka9-J9JKMYem; Wed, 1 Aug 2012 20:19:09 +0400 X-Yandex-Rcpt-Suid: matthewlmcclure@gmail.com X-Yandex-Rcpt-Suid: help-gnu-emacs@gnu.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1343837949; bh=3MkW4knteucGAYghS9KxEqUO9m1ffwyAHPmlV57g13c=; h=Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject: Content-Type:Content-Transfer-Encoding; b=eqe95nG27sgIwle/n0N2zJKPZItN6lALwXNSFrXHgUaxge5ZG62DWyYJGTGT5yHeq RYAVjxpglSYC7f5Dt+w5A5GENyKebmPtvvh47svqU6QUu7Q642SfG7ASVQF6DfAlCh 0RLuTtqtvATU6bRwW2W5/AVvgtckQFNCdiaFfUJE= User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20120713 Thunderbird/14.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 77.88.46.6 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:86148 Archived-At: Hi Matt, Matt McClure writes: > Emacs opens files from one of my largest Git repositories very slowly. It looks > like it spends most of that time waiting for `git diff-index -z HEAD -- `. > > I upgraded this morning to > http://emacsformacosx.com/emacs-builds/Emacs-2012-07-28-109240-universal-10.6.8.dmg > hoping that it would include the fix for > http://debbugs.gnu.org/cgi/bugreport.cgi?bug=11757 and that that would make > Emacs fast enough. But it was still very slow. 11757 was totally unrelated. > I see there's another open ticket citing the call to `git diff-index` from > `vc-git-state`: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8288 > > Applying the workaround from comment 14 in that ticket works for me, but it > seems like it would be better to address the problem closer to the root in the > Emacs source and/or in Git. > > What would you recommend? I'd recommend timing 'git diff-index -z HEAD -- ' vs 'git status --short ' vs 'git status -z --porcelain ' in the console on your real repository and posting the numbers to the bug 8288. And maybe contributing an example patch that works for you. The function responsible for this is `vc-git-state'. --Dmitry