[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#4558: forw_comment slowdown since 22.3
From: |
Dan Nicolaescu |
Subject: |
bug#4558: forw_comment slowdown since 22.3 |
Date: |
Fri, 25 Sep 2009 15:47:54 -0700 (PDT) |
$ cd emacs/src
$ cat emacs.c emacs.c emacs.c emacs.c emacs.c > /tmp/emacs.c
$ emacs /tmp/emacs.c
C-x h
M-;
C-x C-s
C-x C-c
$ cat /tmp/t.el
(defun myfwd ()
(interactive)
(dotimes (n 1)
(while (forward-comment 1))
(while (forward-comment -1)))
(save-buffers-kill-emacs))
;; increase N if your machine is much faster
Now do:
emacs -Q -l /tmp/t.el /tmp/emacs.c -f myfwd
with both CVS HEAD and 22.3.
The gprof results with 22.3:
Each sample counts as 0.01 seconds.
% cumulative self self total
time seconds seconds calls s/call s/call name
81.40 4.90 4.90 5200163 0.00 0.00 forw_comment
12.62 5.66 0.76 642 0.00 0.01 scan_sexps_forward
0.83 5.71 0.05 34941 0.00 0.00 back_comment
0.66 5.75 0.04 1282235 0.00 0.00 char_quoted
0.66 5.79 0.04 13498 0.00 0.00 re_search_2
0.66 5.83 0.04 10738 0.00 0.00 mark_object
0.33 5.85 0.02 54716 0.00 0.00 read1
0.33 5.87 0.02 38404 0.00 0.00 Feval
0.33 5.89 0.02 38012 0.00 0.00 Fbyte_code
0.17 5.90 0.01 183599 0.00 0.00 specbind
0.17 5.91 0.01 99154 0.00 0.00 find_interval
0.17 5.92 0.01 61433 0.00 0.00 get_keymap
0.17 5.93 0.01 37912 0.00 0.00 funcall_lambda
0.17 5.94 0.01 23239 0.00 0.00 oblookup
0.17 5.95 0.01 18737 0.00 0.00 scan_newline
0.17 5.96 0.01 12410 0.00 0.00 get_keyelt
0.17 5.97 0.01 664 0.00 0.00 append_glyph
0.17 5.98 0.01 515 0.00 0.00 re_compile_pattern
0.17 5.99 0.01 7 0.00 0.00 detect_coding_mask
0.17 6.00 0.01 3 0.00 0.00 decode_eol
and with CVS HEAD:
Each sample counts as 0.01 seconds.
% cumulative self self total
time seconds seconds calls s/call s/call name
84.45 6.30 6.30 5200163 0.00 0.00 forw_comment
9.12 6.98 0.68 642 0.00 0.01 scan_sexps_forward
1.47 7.09 0.11 34941 0.00 0.00 back_comment
1.21 7.18 0.09 1747491 0.00 0.00 mark_object
0.40 7.21 0.03 1282235 0.00 0.00 char_quoted
0.40 7.24 0.03 50653 0.00 0.00 re_search_2
0.27 7.26 0.02 768825 0.00 0.00 readchar
0.27 7.28 0.02 738707 0.00 0.00 Faref
0.27 7.30 0.02 25406 0.00 0.00 re_compile_pattern
0.27 7.32 0.02 12264 0.00 0.00 mem_insert
0.13 7.33 0.01 890859 0.00 0.00 mark_vectorlike
0.13 7.34 0.01 739728 0.00 0.00 readbyte_from_file
0.13 7.35 0.01 104164 0.00 0.00
balance_possible_root_interval
0.13 7.36 0.01 64037 0.00 0.00 re_match_2_internal
0.13 7.37 0.01 34284 0.00 0.00 update_syntax_table
0.13 7.38 0.01 25395 0.00 0.00 re_compile_fastmap
0.13 7.39 0.01 21718 0.00 0.00 oblookup
0.13 7.40 0.01 21080 0.00 0.00 multibyte_chars_in_text
0.13 7.41 0.01 1170 0.00 0.00 str_as_unibyte
0.13 7.42 0.01 529 0.00 0.00 mark_char_table
0.13 7.43 0.01 10 0.00 0.01 Fgarbage_collect
0.13 7.44 0.01 10 0.00 0.00 free_glyph_matrix
0.13 7.45 0.01 3 0.00 0.01 Fparse_partial_sexp
0.07 7.46 0.01 158439 0.00 0.00
multibyte_char_to_unibyte_safe
0.07 7.46 0.01 multibyte_char_to_unibyte
0.00 7.46 0.00 727705 0.00 0.00 char_table_translate
0.00 7.46 0.00 205798 0.00 0.00 Fcdr
The same number of calls to forw_comment take longer with CVS HEAD.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#4558: forw_comment slowdown since 22.3,
Dan Nicolaescu <=