Subject: bug#30731: Slower startup using March (27.0.50) build in windows

From: Shuguang Sun <[email-masked]>
Date: Wed, 14 Mar 2018 13:02:39 +0800

The diff files compares the loading time given package initialized early or
late. And I attached a list of packages I installed.

On Wed, Mar 14, 2018 at 9:38 AM, Noam Postavsky <[email-masked]> wrote:

> Shuguang Sun <[email-masked]> writes:
>
> > The trace-log from package-earlyload has less
> > do-after-load-evaluation items which are supposed to be loaded during
> > the package-initialize. However, it still takes longer time for
> > custom-set-variables  during early package initialization.
> > The two items, mail-prsvr.elc and mm-util.elc are in earlyload but
> > not in lateload.
>
> Hmm, somehow that was not so informative as I'd have hoped.  Maybe
> measuring each setting individually would give more info, try this:
>
> (require 'pcase)
>
> (defmacro split-custom-set-variables (cset-form)
>   (pcase cset-form
>     (`(custom-set-variables . ,entries)
>      `(progn
>         ,@(mapcar
>            (pcase-lambda (`(quote (,sym . ,args)))
>              `(let ((t0 (current-time))
>                     (tf nil))
>                 (custom-set-variables (quote (,sym . ,args)))
>                 (setq tf (current-time))
>                 (message "setting `%s': %.3fs" ',sym
>                          (float-time (time-subtract tf t0)))))
>            entries)))))
>
> (split-custom-set-variables
>  (custom-set-variables
>   ...))
>
>