Add gcmh and move gc config to early-init.el

This commit is contained in:
Jeremy Dormitzer 2021-03-19 12:13:43 -04:00
parent 13a3837f45
commit f88496cf58
2 changed files with 11 additions and 2 deletions

View File

@ -0,0 +1,5 @@
;; -*- lexical-binding: t; -*-
;; Some startup time optimizations stolen from Doom emacs
(setq gc-cons-threshold most-positive-fixnum ; 2^61 bytes
gc-cons-percentage 0.6)

View File

@ -1,8 +1,6 @@
;; -*- lexical-binding: t; -*-
;; Some startup time optimizations stolen from Doom emacs
(setq gc-cons-threshold most-positive-fixnum ; 2^61 bytes
gc-cons-percentage 0.6)
(defvar file-name-handler-alist-backup file-name-handler-alist)
(setq file-name-handler-alist nil)
(add-hook 'emacs-startup-hook
@ -37,6 +35,12 @@
(straight-use-package 'use-package)
(setq straight-use-package-by-default t)
;; "Garbage Collection Magic Hack"
(use-package gcmh
:demand t
:config
(gcmh-mode 1))
;; Fix $PATH
(use-package exec-path-from-shell
:hook (after-init . exec-path-from-shell-initialize)