;;-------------------------------------------------------------------- ;; -------------------------------------------------------------------- ;; ;; RSS: 8692 MB ;; ;;-------------------------------------------------------------------- ;;-------------------------------------------------------------------- (let ((size 0)) (dolist (buffer (buffer-list) size) (setq size (+ size (buffer-size buffer))))) 66396004 ;;(profiler-start) (let ((time (current-time)) (result (garbage-collect))) (message "%.06f: %s" (float-time (time-since time)) result)) "3009.961430: ((conses 16 3206773 6144133) (symbols 48 33073 345) (strings 32 648410 1369163) (string-bytes 1 19599515) (vectors 16 628704) (vector-slots 8 42038734 16427823) (floats 8 2298 28700) (intervals 56 37766 23163) (buffers 992 53))" ;;(profiler-report) - ... 901307 99% Automatic GC 901281 99% + trev/slack--refresh-cache 19 0% + slack-users-info-request 3 0% + treemacs-collapse-slack-root-top 2 0% + # 1 0% + slack-user-info-request 1 0% + command-execute 469 0% + timer-event-handler 381 0% + # 8 0% lui-scroll-post-command 5 0% + redisplay_internal (C function) 4 0% + helm-ff--cache-mode-reset-timer 2 0% + # 2 0% + eldoc-schedule-timer 1 0% + substitute-command-keys 1 0% (apply '+ (cl-loop for thing in (garbage-collect) collect (* (nth 1 thing) (nth 2 thing)))) 488687357 (emacs-pid) 1943820 ;; /proc/$PID/smaps heap 564cd914d000-564ef0a26000 rw-p 00000000 00:00 0 [heap] Size: 8774500 kB KernelPageSize: 4 kB MMUPageSize: 4 kB Rss: 8767780 kB Pss: 8767780 kB Shared_Clean: 0 kB Shared_Dirty: 0 kB Private_Clean: 724 kB Private_Dirty: 8767056 kB Referenced: 8736612 kB Anonymous: 8767780 kB LazyFree: 0 kB AnonHugePages: 0 kB ShmemPmdMapped: 0 kB FilePmdMapped: 0 kB Shared_Hugetlb: 0 kB Private_Hugetlb: 0 kB Swap: 5368 kB SwapPss: 5368 kB Locked: 0 kB THPeligible: 0 ProtectionKey: 0 ;; (malloc-info) ;; virtual memory, not RSS (memory-limit) 9967400 (message "%f" gc-cons-threshold) "800000.000000" (message "%f" gc-cons-percentage) "0.100000" (emacs-uptime) "2 days, 2 hours, 40 minutes, 48 seconds" (message "%f" gcs-done) "1085.000000" (message "%f" gc-elapsed) "463.110950" (message "%s" memory-full) "nil" (memory-use-counts) (830154723 1274603 745378434 79269 3126679789 857209 117351091) (apply '+ (memory-use-counts)) 4821820895 (memory-usage) ((conses 16 3428981 5779821) (symbols 48 33520 10) (strings 32 687833 1307854) (string-bytes 1 20381162) (vectors 16 660193) (vector-slots 8 47161498 16021937) (floats 8 2297 27957) (intervals 56 38116 19735) (buffers 992 56)) => 52.3MB (+ 88.2MB dead) in conses 1.53MB (+ 0.47kB dead) in symbols 21.0MB (+ 39.9MB dead) in strings 19.4MB in string-bytes 10.1MB in vectors 360MB (+ 122MB dead) in vector-slots 17.9kB (+ 218kB dead) in floats 2.04MB (+ 1.05MB dead) in intervals 54.2kB in buffers Total in lisp objects: 718MB (live 466MB, dead 252MB) Buffer ralloc memory usage: 56 buffers 64.3MB total ( 542kB in gaps) ;; print all timers (progn (setq timers '()) (cl-loop for tim in timer-list do (push (timer--function tim) timers)) (cl-loop for tim in timer-idle-list do (push (timer--function tim) timers)) (cl-loop for tim in timers do (message "timer: %s" tim))) timer: snitch--prune-log-buffer timer: helm-ff--cache-mode-refresh timer: blink-cursor-start timer: #[0 ?\205\301 \207 [jit-lock--antiblink-grace-timer jit-lock-context-fontify] 1] timer: #[0 \204 \205\302 \205\3031\304 0\207\305\306"\210\307\262\207 [eldoc-mode global-eldoc-mode eldoc--supported-p (debug error) eldoc-print-current-symbol-info message eldoc error: %s nil] 4] timer: slack-ws-ping [5 times] timer: undo-auto--boundary-timer timer: trev/slack--refresh-cache timer: slack-typing-display [10 times] ;; ;; printf in emacs around garbage_collect() ;; ;; 8 hours between the last garbage collect and the manual one ;; all 3000 seconds (50 minutes) in the C function ;; 1607695355: garbage_collect start 1607695356: gc_sweep start 1607695356: gc_sweep end (0 s) 1607695356: garbage_collect #1083 end (1 s) 1607695479: garbage_collect start 1607695480: gc_sweep start 1607695480: gc_sweep end (0 s) 1607695480: garbage_collect #1084 end (1 s) 1607695679: garbage_collect start 1607695680: gc_sweep start 1607695680: gc_sweep end (0 s) 1607695680: garbage_collect #1085 end (1 s) 1607695761: garbage_collect start 1607695762: gc_sweep start 1607695762: gc_sweep end (0 s) 1607726912: garbage_collect start 1607726913: gc_sweep start 1607729921: gc_sweep end (3008 s) 1607729922: garbage_collect #1086 end (3010 s) 1607729955: garbage_collect start 1607729956: gc_sweep start 1607729962: gc_sweep end (6 s) 1607729962: garbage_collect #1087 end (7 s) 1607729964: garbage_collect start 1607729965: gc_sweep start 1607729966: gc_sweep end (1 s) 1607729966: garbage_collect #1088 end (2 s) 1607729968: garbage_collect start 1607729969: gc_sweep start 1607729970: gc_sweep end (1 s) 1607729970: garbage_collect #1089 end (2 s) 1607729972: garbage_collect start 1607729973: gc_sweep start 1607729974: gc_sweep end (1 s) 1607729974: garbage_collect #1090 end (2 s) 1607730032: garbage_collect start 1607730033: gc_sweep start 1607730035: gc_sweep end (2 s) 1607730035: garbage_collect #1091 end (3 s)