From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Shuguang Sun Newsgroups: gmane.emacs.bugs Subject: bug#30731: Slower startup using March (27.0.50) build in windows Date: Mon, 12 Mar 2018 01:21:50 +0800 Message-ID: References: <87a7vi1151.fsf@gmail.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a11487d32d2e4020567264287" X-Trace: blaine.gmane.org 1520788817 2396 195.159.176.226 (11 Mar 2018 17:20:17 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 11 Mar 2018 17:20:17 +0000 (UTC) Cc: 30731@debbugs.gnu.org To: Noam Postavsky Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Mar 11 18:20:13 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1ev4do-0000U3-LR for geb-bug-gnu-emacs@m.gmane.org; Sun, 11 Mar 2018 18:20:12 +0100 Original-Received: from localhost ([::1]:55034 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ev4fp-0003kc-Dm for geb-bug-gnu-emacs@m.gmane.org; Sun, 11 Mar 2018 13:22:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35299) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ev4ff-0003k4-OQ for bug-gnu-emacs@gnu.org; Sun, 11 Mar 2018 13:22:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ev4fa-0000UW-N3 for bug-gnu-emacs@gnu.org; Sun, 11 Mar 2018 13:22:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:47734) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ev4fa-0000UO-I2 for bug-gnu-emacs@gnu.org; Sun, 11 Mar 2018 13:22:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ev4fa-0007Gm-BI for bug-gnu-emacs@gnu.org; Sun, 11 Mar 2018 13:22:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Shuguang Sun Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 11 Mar 2018 17:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 30731 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 30731-submit@debbugs.gnu.org id=B30731.152078891927934 (code B ref 30731); Sun, 11 Mar 2018 17:22:02 +0000 Original-Received: (at 30731) by debbugs.gnu.org; 11 Mar 2018 17:21:59 +0000 Original-Received: from localhost ([127.0.0.1]:55631 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ev4fW-0007GU-JB for submit@debbugs.gnu.org; Sun, 11 Mar 2018 13:21:58 -0400 Original-Received: from mail-qk0-f176.google.com ([209.85.220.176]:40119) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ev4fU-0007GD-IO for 30731@debbugs.gnu.org; Sun, 11 Mar 2018 13:21:57 -0400 Original-Received: by mail-qk0-f176.google.com with SMTP id o25so9023209qkl.7 for <30731@debbugs.gnu.org>; Sun, 11 Mar 2018 10:21:56 -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 :cc; bh=ff/tUe9qxsR7RH3bQJ4EAZhF6bhr2e6o87ilyP6mWHI=; b=ff2VzqUXJb44REQN6gxD00cy4zleqcRWq4m76sBr0Fm18bYmSvHyCC+kIEakNy/Igb aZ09GomFZKgIeShIBuXtC++gQ2OTv6uRsHACgQjKIO2OQCEGtNpXPphT4x8iUQ1DbGka MLzBva4uPsTHyHUfgOS5MjKr4jTA8+8vFBfjAOca/0VKawc4q6m6IHE3M5MKU16S+hqt vWjqtENFd0lUAiUvzIeVNUzGx3ckaZJ2hUUVq1Am4vi2SPspKFBuvy6cglWQAPjjS2sH SXUUGWrqXhH38IZXE/217DjCoS3hg9rBUMGiYb7eClZzZOEwu0dwDUSCSaRznnYTNDkg rqSg== 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:cc; bh=ff/tUe9qxsR7RH3bQJ4EAZhF6bhr2e6o87ilyP6mWHI=; b=g3HDCUntBETgM49VNLdT9GP2FWyDBb/qgxkmWto/Xx6bEe9cBFawRHLYT6lpCDeBWz YDSx7kkUeCk1fuZx90L2koUiOjhyReAGaK87IG9sBWf8axQsbSMuvUOpXIbyrnNA02TG puhLMD27hjBDOE5wP8zkuTNn/U0FO7HDdZu5zuryxPcZ883G2Qhh6Nq85AKVn+13FSDZ shHG4QjauBNRPLmDEPhQfuC0VCRp8r5chsR2EygUXES3itX+ksLCiUg/s1qv/MUvCVEh dtlIpZWu6ncRPdJOvjSmJ18F7PDwEs4tjK6cOYOCybZrP97Pw2d3MFYU4yGQshMzwyic uFbA== X-Gm-Message-State: AElRT7E4xp8GB3XEEQV4dYfV/XpgOvzJDLcQv+7WHh2rnp1Fb3I6NDGp ZlBRG0Ga3V2O8JZVFwqMT6pyTzNrbdNwGmFVF1I= X-Google-Smtp-Source: AG47ELtZbRzAiKS2JBP49yPKyj45qKIciEY3F1qA+wMwAnmg4vQWwghfMb/3UfosUQaX8ppaRUlQgesun2ebn5W8Fog= X-Received: by 10.55.115.1 with SMTP id o1mr8156333qkc.50.1520788911086; Sun, 11 Mar 2018 10:21:51 -0700 (PDT) Original-Received: by 10.237.47.196 with HTTP; Sun, 11 Mar 2018 10:21:50 -0700 (PDT) In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:144131 Archived-At: --001a11487d32d2e4020567264287 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Noam, I read the disussions and patches, and I find out the 3.692 sec at the beigining seems package initialization (according to the patch in Feb 17). However, I still don't get 1. What is an early init file? 2. Why custom-set-variable get slower? 3. If i want to disable package initialization prior to any thin in the .emacs, but after custom-set-variable and some environment variables setting (e.g. PATH, exec-path), how to do it? Could you help provide an example using my situation? 1) I use a Windows 7 box, and have HOME env variables, and .emacs.d folder under it 2) I have a site-start.el for environment variables setting (e.g. PATH, exec-path) <=3D I thinks this it not critical because it has no speed effe= ct after I delete the site-start.el 3) I have .emacs under HOME, and compile it to .emacs.elc to speed it up 4) I load dired.el and then custom-set-variable, then some frame settings , then initialize package using (setq package-enable-at-startup nil) (package-initialize) and then packages customizations (hooks etc) 5) I don't have default.el or init.el How could I adapt the change in package.el and startup.el? e.g. to disable package initialization at the very begining but start it at some point of the initialization of emacs. On Sun, Mar 11, 2018 at 11:25 AM, Shuguang Sun wrote: > I patched the startup.el and package.el in the installed emacs. They seem= s > not work. I'll try to patch the git source prior to the complilation late= r > when I get time. > > > 1. Even I put the (setq package-enable-at-startup nil) in the top of the > .emacs, it takes 3.692 sec before loading others of the init file. I have= a > site-start.el file, which is suposed to run before .emacs is loaded. Woud > it impact the the load process? NB. the 3.692 does not count the site-sta= rt > in. It is from > (message ">>> start load .emacs: %.3f sec <<<" > (float-time (time-subtract after-init-time > before-init-time))) > > 2. No mather whether I set package-enable-at-startup, it takes about 8 se= c > to load the custom-set-variable. However, it takes only 2.5 sec in the Fe= b > version. > > Symbol's value as variable is void: Info-default-directory-list [14 times= ] > >>> start load .emacs: 3.692 sec <<< > Loading Sun Shuguang=E2=80=99s .emacs file > >>> before custom-set-variables : 4.176 sec <<< > Loading image-file...done > Loading time...done > Loading completion...done > Loading elec-pair...done > Loading icomplete...done > Loading ido...done > Loading avoid...done > Loading savehist...done > Loading paren...done > >>> custom-set-variables time: 12.387 sec <<< > > > On Fri, Mar 9, 2018 at 9:35 AM, Noam Postavsky wrote= : > >> Shuguang Sun writes: >> >> > I built emacs 27 on 4th March, however, the startup gets slower than >> > the build on 4th Feb (which is camparable with the build in https:// >> > alpha.gnu.org/gnu/emacs/pretest/windows/emacs-27/). >> > I'm sorry I don't know how to repeat it using "-q". >> > >> > System: Windows 7 >> >> > Below is the message from 4th March build. >> > 1. It has a warning at the very begining. If start with -q, there >> > will be no such warning. >> > 2. Actually there is nothing before " >>> start load .emacs: 2.575 >> > sec <<< ", however, it still takes 2.574 sec. >> > 3. The load time is longer than the 4th Feb build. >> > >> > Symbol's value as variable is void: Info-default-directory-list [14 >> > times] >> >> Could you try out the patch posted to emacs-devel? >> >> https://lists.gnu.org/archive/html/emacs-devel/2018-03/msg00040.html >> > > --001a11487d32d2e4020567264287 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Noam,

I read the disussions and patches, a= nd I find out the=20 3.692 sec at the beigining seems package initialization (according to the p= atch in Feb 17).
However, I still don't get
1. What= is an early init file?
2. Why=20 custom-set-variable=C2=A0 get slower?
3. If i want to disable package initialization prior = to any thin in the .emacs, but after=20 custom-set-variable and some environment variables setting (e.g. PATH, exec= -path), how to do it?

Could you help provide an ex= ample using my situation?
1) I use a Windows 7 box, and have HOME= env variables, and .emacs.d folder under it
2) I have a site-start.el for=20 environment variables setting (e.g. PATH, exec-path)=C2=A0 <=3D I thinks this it not critical because it has no speed effect after = I delete the site-start.el=20
3) I have .emacs under HOME, and compile it to .emacs.elc to= speed it up
4) I load dired.el and then=20 custom-set-variable, then some frame settings , then initialize package usi= ng
(setq package-enable-at-startup nil)
(package-initializ= e)
and then packages customizations (hooks etc)
5) = I don't have default.el or init.el
=C2=A0
How c= ould I adapt the change in package.el and startup.el? e.g. to disable packa= ge initialization at the very begining but start it at some point of the in= itialization of emacs.



On Sun,= Mar 11, 2018 at 11:25 AM, Shuguang Sun <shuguang@gmail.com> wrote:
I patched = the startup.el and package.el in the installed emacs. They seems not work. = I'll try to patch the git source prior to the complilation later when I= get time.


1. Even I put the (setq = package-enable-at-startup nil) in the top of the .emacs, it takes 3.692 sec= before loading others of the init file. I have a site-start.el file, which= is suposed to run before .emacs is loaded. Woud it impact the the load pro= cess? NB. the 3.692 does not count the site-start in. It is from
=
(message ">>> start load .emacs: %.3f sec <<<&q= uot;
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (float-time (time-su= btract after-init-time before-init-time)))

2. No mather w= hether I set package-enable-at-startup, it takes about 8 sec to load the cu= stom-set-variable. However, it takes only 2.5 sec in the Feb version.

Symbol's value as variable is = void: Info-default-directory-list [14 times]
>>> start l= oad .emacs: 3.692 sec <<<
Loading Sun Shuguang=E2=80=99s .emacs= file
>>> before custom-set-variables : 4.176 sec <<<<= br>Loading image-file...done
Loading time...done
Loading completion..= .done
Loading elec-pair...done
Loading icomplete...done
Loading id= o...done
Loading avoid...done
Loading savehist...done
Loading pare= n...done
>>> custom-set-variables time: 12.387 sec <<<=


On Fri, Mar 9, 2018 at 9:35 AM, = Noam Postavsky <npostavs@gmail.com> wrote:
Shuguang Sun <shuguang@gmail.com> writes:

> I built emacs 27 on 4th March, however, the startup gets slower than > the build on 4th Feb (which is camparable with the build in https:// > alpha.gnu.org/gnu/emacs/pretest/wi= ndows/emacs-27/).
> I'm sorry I don't know how to repeat it using "-q".<= br> >
> System: Windows 7

> Below is the message from 4th March build.
> 1. It has a warning at the very begining. If start with -q, there
> will be no such warning.
> 2. Actually there is nothing before " >>> start load .em= acs: 2.575
> sec <<< ", however, it still takes 2.574 sec.
> 3. The load time is longer than the 4th Feb build.
>
> Symbol's value as variable is void: Info-default-directory-list [1= 4
> times]

Could you try out the patch posted to emacs-devel?

https://lists.gnu.org/archive/html/emacs-devel/2018-03/msg00040.html


--001a11487d32d2e4020567264287--