From 2d310e468ca0202f40a9ea5ffd310d41f7d22dcb Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Tue, 2 Apr 2024 19:40:53 -0700 Subject: some cleanup around GC --- early-init.el | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'early-init.el') diff --git a/early-init.el b/early-init.el index ab93a23..0312190 100644 --- a/early-init.el +++ b/early-init.el @@ -4,6 +4,10 @@ ;;; Code: +;; make garbage collector less invasive +(setq gc-cons-threshold most-positive-fixnum) +(setq gc-cons-percentage 0.6) + ;; disable GUI elements (scroll-bar-mode -1) ; hide the scroll bar (tool-bar-mode -1) ; hide the tool bar @@ -14,10 +18,14 @@ (setq use-dialog-box nil) ;; do not show GUI dialogs (setq inhibit-startup-screen t) ;; hide the startup screen -;; don't report warnings and errors related to native compilation -(setq native-comp-async-report-warnings-errors nil) - ;; increase font size (set-face-attribute 'default nil :height 130) +(add-hook + 'emacs-startup-hook + (lambda (&rest _) + (setq garbage-collection-messages t) ;; log when the gc kicks in + (setq gc-cons-threshold 16777216) ;; 16mb + (setq gc-cons-percentage 0.1))) + ;;; early-init.el ends here -- cgit 1.4.1