From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: XeCycle Newsgroups: gmane.emacs.help Subject: Re: vc-git slows Emacs down quite a bit, trying to find a way to remove hooks Date: Tue, 27 Mar 2012 10:05:41 +0800 Message-ID: <87aa32re6i.fsf@Gmail.com> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: dough.gmane.org 1332813971 6202 80.91.229.3 (27 Mar 2012 02:06:11 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 27 Mar 2012 02:06:11 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Mar 27 04:06:09 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 1SCLnT-0006qa-Dx for geh-help-gnu-emacs@m.gmane.org; Tue, 27 Mar 2012 04:06:07 +0200 Original-Received: from localhost ([::1]:43005 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SCLnS-0002bU-Lp for geh-help-gnu-emacs@m.gmane.org; Mon, 26 Mar 2012 22:06:06 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:57091) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SCLnN-0002at-5l for help-gnu-emacs@gnu.org; Mon, 26 Mar 2012 22:06:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SCLnL-0006li-CL for help-gnu-emacs@gnu.org; Mon, 26 Mar 2012 22:06:00 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:42013) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SCLnL-0006lN-5M for help-gnu-emacs@gnu.org; Mon, 26 Mar 2012 22:05:59 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1SCLnH-0006jt-1J for help-gnu-emacs@gnu.org; Tue, 27 Mar 2012 04:05:55 +0200 Original-Received: from 59.78.37.25 ([59.78.37.25]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 27 Mar 2012 04:05:55 +0200 Original-Received: from XeCycle by 59.78.37.25 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 27 Mar 2012 04:05:55 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 58 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 59.78.37.25 User-Agent: Gnus/5.130004 (Ma Gnus v0.4) Emacs/24.0.94 (gnu/linux) Cancel-Lock: sha1:IdyvYuuSnGuQtxI/Tlwm6JbFelY= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 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:84107 Archived-At: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Wei Liu writes: > Hi all Hello. > I find that vc-git takes quite a lot of time to load, both in Emacs 23 > and Emacs snapshot. On my dev machine it takes up to 21 seconds. :-( > > I don't want to disable vc-mode entirely, I just want to make sure > that vc-git doesn' t get loaded when I don't need it. See variable vc-handled-backends. If you need it sometimes, just set the variable temporarily back, e.g. using directory-local variables. > There was a topic [0] on this issue on stackoverflow. I took the > advice to remove vc-find-file-hook from fine-file-hook list, thus > speeding up Emacs a lot. But when I save file, vc-git gets loaded once > again, which consumes 21 seconds. So my questions are a) how to > disable this save file hook (I grepped in vc-*.el, didn't find > save-*-hook), b) are there any other hooks I need to take care of? a) Probably don't need that. b) Same as a. > Extra questions (to developers and/or Emacs gurus): Why is vc-git so > slow (see [0] for profiling details)? Is there a genuine way to fix > this? Dunno, when viewing my local Emacs repo it isn't slow. I don't want to clone the kernel repo though. =2D-=20 Carl Lei (XeCycle) Department of Physics, Shanghai Jiao Tong University OpenPGP public key: 7795E591 Fingerprint: 1FB6 7F1F D45D F681 C845 27F7 8D71 8EC4 7795 E591 --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQEcBAEBAgAGBQJPcSB1AAoJEI1xjsR3leWRuYQH/0dc/1bp7QEt+/BJgmYIWTgV 4AIFMwdLv/5lkrx3jvPF/gn0FSzeyXgQ4hZ5OWUrgm9ntikfI3w2AWD1fOttJRGo myg8VLvfrVvbIMJ2iV3FxKsSZpkHfyG4FV/V6ieWeBiui83IRp6QV2cyqSP1PnWp VvJd52pF6uOIc8wYJWjR32X/HH/DSmkADyg8jJhHxtoc+gkfR3SYo33qkKAQbzxn HoC2QFjIpeKoNfZc5aIz+tBzwBiJnHruxbHe/01cY7VttQEGymsf/q+zP9FmLkys fTYHlEWiO1Frncz29Ru/JB6Z5CbYaAI4GQpdcZgzVQKJQhHJg7vsPkncC4m/768= =JlUC -----END PGP SIGNATURE----- --=-=-=--