Skip to content

* doc/FAQ.org: Document for optimizing Spacemacs startup #16939

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions doc/FAQ.org
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
- [[#why-are-all-packages-unavailable][Why are all packages unavailable?]]
- [[#the-powerline-isnt-shown-correctly-when-spacemacs-is-used-within-putty][The powerline isn't shown correctly when Spacemacs is used within =PuTTY=]]
- [[#speedup-the-spacemacs-with-load-hints-feature][Speedup the Spacemacs with load-hints feature]]
- [[#speedup-the-spacemacs-by-optimizing-module-loading][Speedup the Spacemacs by optimizing module loading]]

* Common
** Which version of Spacemacs am I running?
Expand Down Expand Up @@ -672,3 +673,28 @@ Spacemacs implemented the ~load-hints~ feature, controled by the
~load-hints~ feature, then executing the function
~spacemacs//package-regenerate-autoloads~ and restart the Spacemacs to try this
feature to observer it speedups the Spacemacs or not on the Windows OS.

** Speedup the Spacemacs by optimizing module loading
The official Emacs-30.1 release for Windows was built with native module
support. However Spacemacs rarely relies on native module, so we can let Emacs
do NOT searching the =*.dll= or =*.dll.gz= for speed with putting follow lines
to the ~early-init.el~.
#+begin_src elisp
(progn
(setq load-suffixes '(".elc" ".el"))
(message "Dismiss the \".dll\" or \".so\" from `load-suffixes' for speed.\n
Which will affect Emacs loading a native module *.dll or *.so."))
#+end_src

The official Emacs-30.1 for windows also did NOT ship with the compressed
=*.el.gz= or =*.elc.gz=, so adding follow lines to the ~early-init.el~ can avoid
searching =*.gz= files:
#+begin_src elisp
(progn
(setq load-file-rep-suffixes '(""))
(message "Do NOT search \"*.gz\", it maybe lead an error like \"Symbol's value as
variable is void: \213\"."))
#+end_src

These tricks can speedup the Spacemacs on Windows, try them one by one then you
will find the best option combinations.