help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: How to load recentf only after opening/saving a file for thefirsttim


From: Drew Adams
Subject: RE: How to load recentf only after opening/saving a file for thefirsttime?
Date: Fri, 7 Sep 2012 08:48:07 -0700

> The fact is that Emacs (RC 24.2 on Windows) takes around 25 
> seconds to load my (huge, yes) .emacs file (378 KB, ~10 KLOC
> from which a third is white lines, and another one is comment lines).
> Loading Org mode takes another minute or so, with 50 agenda files.
> 
> That's really too much. That's why I'm trying to refactor my 
> .emacs file to try to see what takes time. I'm trying to
> autoload as much as possible, and to delay the `require' calls

I understand.  And that's a good approach.  As you know, you can also use
`eval-after-load' to avoid doing some stuff unnecessarily.

As with any performance problem, start by attacking the biggest hogs.  It sounds
like your 50 Org-mode agenda files constitute 2/3 of your performance problem at
the moment, so perhaps start there.

Do you really need to load all of your Org agenda files?  Do they need to be so
big/slow?  Does Org mode provide any constructs that might alleviate some of
this penalty?

I don't have answers for you, sorry.  Except for this obvious one: try starting
Emacs less often and keeping your Emacs sessions open longer.

Oh, and of course byte-compile the code you load.  (You mention whitespace lines
and commented lines, but those are irrelevant for byte-compiled code.)

And maybe try profiling code for the worst parts of your problem.  Perhaps
you've hit a bug or two, or perhaps you've found an opportunity for some library
to be improved wrt load performance.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]