Last active
April 19, 2022 15:00
-
-
Save nanzhong/773c629a4cfcba42de199a66a6359993 to your computer and use it in GitHub Desktop.
hl-line-mode + projectile slow down
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'package) | |
(setq package-enable-at-startup nil) | |
(add-to-list 'package-archives | |
'("melpa" . "https://melpa.org/packages/")) | |
(package-initialize) | |
(unless (package-installed-p 'use-package) | |
(package-refresh-contents) | |
(package-install 'use-package)) | |
(global-hl-line-mode 1) | |
(add-hook 'prog-mode-hook (lambda () (linum-mode 1))) | |
(use-package projectile | |
:ensure t | |
:config | |
(projectile-global-mode)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- linum-update-current 1511 41% | |
- linum-update 1509 41% | |
- mapc 1508 41% | |
- linum-update-window 1438 39% | |
linum--face-width 40 1% | |
line-number-at-pos 19 0% | |
- display-graphic-p 2 0% | |
framep-on-display 1 0% | |
- redisplay_internal (C function) 1300 35% | |
- eval 1220 33% | |
- if 1219 33% | |
- format 1219 33% | |
- projectile-project-name 1218 33% | |
- projectile-project-root 1218 33% | |
- cl-some 1217 33% | |
- #<compiled 0x42a209db> 1217 33% | |
- file-truename 608 16% | |
- file-truename 550 15% | |
- file-truename 464 12% | |
- tramp-completion-file-name-handler 464 12% | |
- let 464 12% | |
- if 464 12% | |
- tramp-completion-run-real-handler 464 12% | |
- let* 464 12% | |
- apply 464 12% | |
- file-truename 464 12% | |
- file-symlink-p 460 12% | |
- tramp-completion-file-name-handler 460 12% | |
- let 460 12% | |
- if 460 12% | |
- tramp-completion-run-real-handler 460 12% | |
- let* 460 12% | |
- apply 459 12% | |
file-symlink-p 1 0% | |
- file-name-directory 2 0% | |
- tramp-completion-file-name-handler 2 0% | |
- let 1 0% | |
- if 1 0% | |
- tramp-completion-run-real-handler 1 0% | |
- let* 1 0% | |
apply 1 0% | |
- directory-file-name 1 0% | |
tramp-completion-file-name-handler 1 0% | |
- file-name-as-directory 1 0% | |
- tramp-completion-file-name-handler 1 0% | |
- let 1 0% | |
- if 1 0% | |
- tramp-completion-run-real-handler 1 0% | |
- let* 1 0% | |
apply 1 0% | |
- projectile-root-bottom-up 549 14% | |
- cl-some 549 14% | |
- #<compiled 0x42a10ddb> 549 14% | |
- projectile-locate-dominating-file 549 14% | |
projectile-file-exists-p 547 14% | |
- projectile-root-top-down-recurring 58 1% | |
- cl-some 58 1% | |
- #<compiled 0x42a07ddb> 58 1% | |
- projectile-locate-dominating-file 58 1% | |
- #<compiled 0x40caef7b> 58 1% | |
projectile-file-exists-p 58 1% | |
- unless 1 0% | |
- if 1 0% | |
display-graphic-p 1 0% | |
- linum-after-scroll 79 2% | |
- linum-update 79 2% | |
- mapc 79 2% | |
- linum-update-window 79 2% | |
- window-end 51 1% | |
- jit-lock-function 51 1% | |
- jit-lock-fontify-now 51 1% | |
#<compiled 0x42a4b1db> 34 0% | |
- jit-lock--run-functions 17 0% | |
- run-hook-wrapped 16 0% | |
- #<compiled 0x42a4a5f3> 16 0% | |
- font-lock-fontify-region 16 0% | |
- font-lock-default-fontify-region 16 0% | |
- font-lock-fontify-keywords-region 12 0% | |
- go--match-func 1 0% | |
- go--match-func-type-names 1 0% | |
- go--match-parameter-list 1 0% | |
- go--match-parameters-with-identifier-list 1 0% | |
go--match-parameters-common 1 0% | |
font-lock-fontify-syntactically-region 2 0% | |
line-number-at-pos 1 0% | |
- command-execute 434 11% | |
- call-interactively 433 11% | |
- byte-code 346 9% | |
- read-extended-command 346 9% | |
- completing-read 346 9% | |
- completing-read-default 346 9% | |
- read-from-minibuffer 241 6% | |
- redisplay_internal (C function) 218 5% | |
- eval 217 5% | |
- if 217 5% | |
- format 217 5% | |
- projectile-project-name 217 5% | |
- projectile-project-root 217 5% | |
- cl-some 217 5% | |
- #<compiled 0x40cab30b> 217 5% | |
- projectile-root-top-down 216 5% | |
- projectile-locate-dominating-file 216 5% | |
- #<compiled 0x4055b5f3> 216 5% | |
- cl-find-if 216 5% | |
- apply 216 5% | |
- cl-find 216 5% | |
- apply 216 5% | |
- cl-position 216 5% | |
- cl--position 216 5% | |
- #<compiled 0x4049ebe5> 216 5% | |
projectile-file-exists-p 211 5% | |
- projectile-root-top-down-recurring 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x42a0a1db> 1 0% | |
- projectile-locate-dominating-file 1 0% | |
- #<compiled 0x42a0a1e7> 1 0% | |
projectile-file-exists-p 1 0% | |
- tool-bar-make-keymap 1 0% | |
- tool-bar-make-keymap-1 1 0% | |
- mapcar 1 0% | |
- #<compiled 0x400f1c75> 1 0% | |
- eval 1 0% | |
- find-image 1 0% | |
image-search-load-path 1 0% | |
- command-execute 1 0% | |
- call-interactively 1 0% | |
funcall-interactively 1 0% | |
- funcall-interactively 87 2% | |
- next-line 60 1% | |
- line-move 60 1% | |
line-move-visual 27 0% | |
- window-inside-pixel-edges 11 0% | |
- window-edges 8 0% | |
- window-current-scroll-bars 5 0% | |
frame-current-scroll-bars 3 0% | |
- line-move-partial 6 0% | |
- posn-at-point 1 0% | |
- eval 1 0% | |
- if 1 0% | |
- format 1 0% | |
- projectile-project-name 1 0% | |
- projectile-project-root 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x405fcfed> 1 0% | |
- projectile-root-top-down-recurring 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x42a075db> 1 0% | |
- projectile-locate-dominating-file 1 0% | |
- #<compiled 0x42a081db> 1 0% | |
projectile-file-exists-p 1 0% | |
- default-line-height 1 0% | |
default-font-height 1 0% | |
- window-screen-lines 1 0% | |
- default-line-height 1 0% | |
default-font-height 1 0% | |
- default-line-height 6 0% | |
default-font-height 3 0% | |
- execute-extended-command 27 0% | |
- sit-for 22 0% | |
- redisplay 11 0% | |
- redisplay_internal (C function) 2 0% | |
- tool-bar-make-keymap 1 0% | |
- tool-bar-make-keymap-1 1 0% | |
- mapcar 1 0% | |
- #<compiled 0x400f1c75> 1 0% | |
- eval 1 0% | |
- find-image 1 0% | |
image-search-load-path 1 0% | |
- eval 1 0% | |
- if 1 0% | |
- format 1 0% | |
- projectile-project-name 1 0% | |
- projectile-project-root 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x40d65089> 1 0% | |
- projectile-root-top-down-recurring 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x405dd801> 1 0% | |
- projectile-locate-dominating-file 1 0% | |
- #<compiled 0x4062126b> 1 0% | |
projectile-file-exists-p 1 0% | |
- command-execute 5 0% | |
- call-interactively 5 0% | |
- funcall-interactively 5 0% | |
- profiler-report 4 0% | |
- profiler-report-cpu 4 0% | |
profiler-cpu-profile 3 0% | |
profiler-start 1 0% | |
- ... 420 11% | |
Automatic GC 420 11% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- command-execute 9648 84% | |
- call-interactively 9647 84% | |
- funcall-interactively 7685 66% | |
- next-line 7657 66% | |
- line-move 7654 66% | |
- line-move-partial 7526 65% | |
- pos-visible-in-window-p 4511 39% | |
- eval 4504 39% | |
- if 4500 39% | |
- format 4484 39% | |
- projectile-project-name 4484 39% | |
- projectile-project-root 4484 39% | |
- cl-some 4481 39% | |
- #<compiled 0x42ae4edb> 4481 39% | |
- file-truename 3829 33% | |
- file-truename 3722 32% | |
- file-truename 3568 31% | |
- tramp-completion-file-name-handler 3562 31% | |
- let 3560 31% | |
- if 3559 31% | |
- tramp-completion-run-real-handler 3559 31% | |
- let* 3558 31% | |
- apply 3558 31% | |
- file-truename 3548 30% | |
- file-symlink-p 3466 30% | |
- tramp-completion-file-name-handler 3464 30% | |
- let 3464 30% | |
- if 3464 30% | |
- tramp-completion-run-real-handler 3463 30% | |
- let* 3460 30% | |
- apply 3455 30% | |
- file-symlink-p 15 0% | |
- tramp-completion-file-name-handler 15 0% | |
- let 15 0% | |
- if 15 0% | |
- tramp-completion-run-real-handler 15 0% | |
- let* 12 0% | |
apply 12 0% | |
- cons 2 0% | |
- cons 2 0% | |
- cons 2 0% | |
and 1 0% | |
- file-name-nondirectory 34 0% | |
- tramp-completion-file-name-handler 34 0% | |
- let 31 0% | |
- if 31 0% | |
- tramp-completion-run-real-handler 28 0% | |
- let* 25 0% | |
apply 20 0% | |
- cons 4 0% | |
cons 3 0% | |
- file-name-directory 15 0% | |
- tramp-completion-file-name-handler 15 0% | |
- let 15 0% | |
- if 15 0% | |
- tramp-completion-run-real-handler 14 0% | |
- let* 12 0% | |
apply 11 0% | |
- cons 1 0% | |
- cons 1 0% | |
- cons 1 0% | |
and 1 0% | |
- directory-file-name 9 0% | |
- tramp-completion-file-name-handler 9 0% | |
- let 8 0% | |
- if 8 0% | |
- tramp-completion-run-real-handler 8 0% | |
- let* 7 0% | |
- cons 4 0% | |
- cons 1 0% | |
cons 1 0% | |
apply 2 0% | |
- file-name-as-directory 2 0% | |
- tramp-completion-file-name-handler 2 0% | |
- let 2 0% | |
- if 2 0% | |
- tramp-completion-run-real-handler 2 0% | |
- let* 2 0% | |
apply 2 0% | |
- projectile-root-bottom-up 407 3% | |
- cl-some 406 3% | |
- #<compiled 0x42b00edb> 406 3% | |
- projectile-locate-dominating-file 405 3% | |
- projectile-file-exists-p 379 3% | |
file-remote-p 2 0% | |
- abbreviate-file-name 3 0% | |
#<compiled 0x42ae26db> 1 0% | |
- projectile-root-top-down-recurring 228 1% | |
- cl-some 228 1% | |
- #<compiled 0x40554a39> 228 1% | |
- projectile-locate-dominating-file 227 1% | |
- #<compiled 0x40554879> 225 1% | |
- projectile-file-exists-p 217 1% | |
file-remote-p 1 0% | |
- abbreviate-file-name 1 0% | |
#<compiled 0x40c3cb75> 1 0% | |
- projectile-root-top-down 3 0% | |
- projectile-locate-dominating-file 3 0% | |
- #<compiled 0x42b022db> 3 0% | |
- cl-find-if 3 0% | |
- apply 3 0% | |
- cl-find 3 0% | |
- apply 3 0% | |
cl-position 2 0% | |
file-remote-p 4 0% | |
- display-graphic-p 2 0% | |
framep-on-display 1 0% | |
frame-parameter 1 0% | |
mode-line-eol-desc 1 0% | |
file-remote-p 6 0% | |
- posn-at-point 244 2% | |
- eval 243 2% | |
- if 242 2% | |
- format 238 2% | |
- projectile-project-name 238 2% | |
- projectile-project-root 238 2% | |
- cl-some 237 2% | |
- #<compiled 0x404521a7> 236 2% | |
- projectile-root-bottom-up 96 0% | |
- cl-some 96 0% | |
- #<compiled 0x404521b7> 96 0% | |
- projectile-locate-dominating-file 96 0% | |
- projectile-file-exists-p 94 0% | |
file-remote-p 1 0% | |
- projectile-root-top-down-recurring 83 0% | |
- cl-some 83 0% | |
- #<compiled 0x404c0ef9> 83 0% | |
- projectile-locate-dominating-file 83 0% | |
- #<compiled 0x404c0f7f> 82 0% | |
projectile-file-exists-p 82 0% | |
abbreviate-file-name 1 0% | |
- file-truename 50 0% | |
- file-truename 29 0% | |
- file-truename 1 0% | |
- tramp-completion-file-name-handler 1 0% | |
let 1 0% | |
- display-graphic-p 1 0% | |
framep-on-display 1 0% | |
frame-parameter 1 0% | |
- window-screen-lines 11 0% | |
- default-line-height 6 0% | |
default-font-height 4 0% | |
- window-inside-pixel-edges 4 0% | |
- window-edges 4 0% | |
- window-current-scroll-bars 2 0% | |
frame-current-scroll-bars 1 0% | |
default-font-height 6 0% | |
- default-line-height 6 0% | |
default-font-height 3 0% | |
- window-inside-pixel-edges 6 0% | |
- window-edges 6 0% | |
- window-current-scroll-bars 6 0% | |
frame-current-scroll-bars 6 0% | |
- line-move-visual 93 0% | |
- posn-at-point 8 0% | |
- eval 8 0% | |
- if 8 0% | |
- format 8 0% | |
- projectile-project-name 7 0% | |
- projectile-project-root 7 0% | |
- cl-some 7 0% | |
- #<compiled 0x42a9a8bd> 7 0% | |
- projectile-root-bottom-up 6 0% | |
- cl-some 6 0% | |
- #<compiled 0x42a9a8cd> 6 0% | |
- projectile-locate-dominating-file 6 0% | |
projectile-file-exists-p 6 0% | |
- projectile-root-top-down-recurring 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x40555f81> 1 0% | |
- projectile-locate-dominating-file 1 0% | |
- #<compiled 0x40c3cb4b> 1 0% | |
projectile-file-exists-p 1 0% | |
- window-inside-pixel-edges 9 0% | |
- window-edges 8 0% | |
- window-current-scroll-bars 7 0% | |
frame-current-scroll-bars 7 0% | |
- default-line-height 8 0% | |
default-font-height 4 0% | |
called-interactively-p 1 0% | |
- execute-extended-command 27 0% | |
- sit-for 23 0% | |
- redisplay 12 0% | |
- redisplay_internal (C function) 1 0% | |
- tool-bar-make-keymap 1 0% | |
- tool-bar-make-keymap-1 1 0% | |
- mapcar 1 0% | |
- #<compiled 0x400f1c75> 1 0% | |
- eval 1 0% | |
- find-image 1 0% | |
image-search-load-path 1 0% | |
- command-execute 4 0% | |
- call-interactively 4 0% | |
- funcall-interactively 4 0% | |
- profiler-report 3 0% | |
- profiler-report-cpu 3 0% | |
profiler-cpu-profile 3 0% | |
profiler-start 1 0% | |
- byte-code 1961 17% | |
- read-extended-command 1961 17% | |
- completing-read 1961 17% | |
- completing-read-default 1961 17% | |
- read-from-minibuffer 1858 16% | |
- redisplay_internal (C function) 1840 16% | |
- eval 1838 16% | |
- if 1838 16% | |
- format 1838 16% | |
- projectile-project-name 1838 16% | |
- projectile-project-root 1838 16% | |
- cl-some 1838 16% | |
- #<compiled 0x42a7bd59> 1838 16% | |
- projectile-root-top-down 1837 16% | |
- projectile-locate-dominating-file 1837 16% | |
- #<compiled 0x42aa21f3> 1837 16% | |
- cl-find-if 1837 16% | |
- apply 1837 16% | |
- cl-find 1837 16% | |
- apply 1837 16% | |
- cl-position 1837 16% | |
- cl--position 1836 16% | |
- #<compiled 0x42aa25e5> 1836 16% | |
- projectile-file-exists-p 1787 15% | |
file-remote-p 7 0% | |
- projectile-root-top-down-recurring 1 0% | |
- cl-some 1 0% | |
- #<compiled 0x42abaaf3> 1 0% | |
- projectile-locate-dominating-file 1 0% | |
- #<compiled 0x42b01edb> 1 0% | |
projectile-file-exists-p 1 0% | |
- tool-bar-make-keymap 2 0% | |
- tool-bar-make-keymap-1 2 0% | |
- mapcar 2 0% | |
- #<compiled 0x400f1c75> 2 0% | |
- eval 2 0% | |
- find-image 2 0% | |
image-search-load-path 2 0% | |
- linum-update-current 1 0% | |
- linum-update 1 0% | |
- mapc 1 0% | |
linum-update-window 1 0% | |
- ... 980 8% | |
Automatic GC 980 8% | |
- linum-update-current 593 5% | |
- linum-update 592 5% | |
- mapc 592 5% | |
- linum-update-window 558 4% | |
linum--face-width 15 0% | |
line-number-at-pos 3 0% | |
- redisplay_internal (C function) 246 2% | |
- eval 189 1% | |
- if 186 1% | |
- format 182 1% | |
- projectile-project-name 182 1% | |
- projectile-project-root 181 1% | |
- cl-some 180 1% | |
- #<compiled 0x404ad295> 180 1% | |
- projectile-root-bottom-up 74 0% | |
- cl-some 74 0% | |
- #<compiled 0x42ab2adb> 74 0% | |
- projectile-locate-dominating-file 74 0% | |
- projectile-file-exists-p 72 0% | |
file-remote-p 1 0% | |
- projectile-root-top-down-recurring 59 0% | |
- cl-some 59 0% | |
- #<compiled 0x42aeceeb> 59 0% | |
- projectile-locate-dominating-file 59 0% | |
- #<compiled 0x42aee2e9> 59 0% | |
projectile-file-exists-p 59 0% | |
- file-truename 43 0% | |
file-truename 20 0% | |
display-graphic-p 1 0% | |
mode-line-eol-desc 1 0% | |
- linum-after-scroll 53 0% | |
- linum-update 53 0% | |
- mapc 53 0% | |
- linum-update-window 53 0% | |
- window-end 39 0% | |
- jit-lock-function 39 0% | |
- jit-lock-fontify-now 39 0% | |
#<compiled 0x405548e5> 31 0% | |
- jit-lock--run-functions 8 0% | |
- run-hook-wrapped 8 0% | |
- #<compiled 0x42ab72db> 8 0% | |
- font-lock-fontify-region 8 0% | |
- font-lock-default-fontify-region 8 0% | |
- font-lock-fontify-keywords-region 7 0% | |
- go--match-func 2 0% | |
- go--match-func-type-names 1 0% | |
- go--match-parameter-list 1 0% | |
- go--parameter-list-type 1 0% | |
go--looking-at-keyword 1 0% | |
font-lock-fontify-syntactically-region 1 0% | |
line-number-at-pos 1 0% | |
- #<compiled 0x41c2f3c5> 2 0% | |
- apply 2 0% | |
redisplay--pre-redisplay-functions 2 0% | |
file-remote-p 2 0% | |
- global-hl-line-highlight 3 0% | |
hl-line-move 3 0% | |
global-hl-line-unhighlight 1 0% |
@AtomicNess123 my setup has changed quite dramatically and I'm no longer experiencing this.
The config here uses linum-mode
which is known to be slower for larger files. You might want to try using display-line-numbers
if you're on emacs 26+.
Thanks. I don't use any numbers mode, just thought that the hl-line-mode was slowing down my processing.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm having this slow down too. Nothing to fix it?