GNU bug report logs -
#58558
29.0.50; re-search-forward is slow in some buffers
Previous Next
Full log
View this message in rfc822 format
Eli Zaretskii <eliz <at> gnu.org> writes:
>> If I read the backtrace correctly, something in my custom mode-line is
>> triggering Fmatch_data that creates markers.
>
> Yes, you have sone :eval form in the mode line, it seems?
Yes. For example, I call
(defun yant/vc-git-current-branch ()
"Get current GIT branch."
(and vc-mode
(cadr (s-match "Git.\\([^ ]+\\)" vc-mode))))
with s-match wrapping its code into save-match-data.
> Calling xbacktrace will show a Lisp backtrace, which could be
> educational here.
(gdb) xbacktrace
Undefined command: "xbacktrace". Try "help".
I am not sure what you mean by xbacktrace.
Also, as Stefan pointed, number of markers may or may not be a problem
here. However, I had a similar issue even with Emacs 28 when we tested
creating a huge number of markers in buffer + re-search-forward. I ended
up seeing similar perf logs that time.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
This bug report was last modified 2 years and 64 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.