unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Shuguang Sun <shuguang@gmail.com>
To: Noam Postavsky <npostavs@gmail.com>
Cc: 30731@debbugs.gnu.org
Subject: bug#30731: Slower startup using March (27.0.50) build in windows
Date: Mon, 12 Mar 2018 01:21:50 +0800	[thread overview]
Message-ID: <CACspjXd1ZiwW9T_roOF6Z-fZPAhfvL0qVBXSUqe95vu=b4p7eQ@mail.gmail.com> (raw)
In-Reply-To: <CACspjXdJ32fGo0mg_Ph50oUU9mRpSn9DpamB4tJQx58=oPxBkw@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 3700 bytes --]

 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)  <= I thinks this it not critical because it has no speed effect
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 <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 process? NB. the 3.692 does not count the site-start
> 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 sec
> to load the custom-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 load .emacs: 3.692 sec <<<
> Loading Sun Shuguang’s .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 <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/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
>>
>
>

[-- Attachment #2: Type: text/html, Size: 5170 bytes --]

  reply	other threads:[~2018-03-11 17:21 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-06 16:20 bug#30731: Slower startup using March (27.0.50) build in windows Shuguang Sun
2018-03-09  1:35 ` Noam Postavsky
2018-03-11  3:25   ` Shuguang Sun
2018-03-11 17:21     ` Shuguang Sun [this message]
2018-03-11 17:39       ` Noam Postavsky
2018-03-12  1:48         ` Shuguang Sun
2018-03-12  1:52           ` Noam Postavsky
2018-03-12 16:08             ` Shuguang Sun
2018-03-12 17:09               ` Noam Postavsky
2018-03-13 10:34                 ` Shuguang Sun
2018-03-14  1:38                   ` Noam Postavsky
2018-03-14  5:02                     ` Shuguang Sun
2018-03-19 23:41                       ` Noam Postavsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CACspjXd1ZiwW9T_roOF6Z-fZPAhfvL0qVBXSUqe95vu=b4p7eQ@mail.gmail.com' \
    --to=shuguang@gmail.com \
    --cc=30731@debbugs.gnu.org \
    --cc=npostavs@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).