Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ts-fold-line-comment-mode is very slow #115

Open
guibor opened this issue Jan 12, 2024 · 4 comments
Open

ts-fold-line-comment-mode is very slow #115

guibor opened this issue Jan 12, 2024 · 4 comments
Labels
question Further information is requested

Comments

@guibor
Copy link

guibor commented Jan 12, 2024

Happy to provide more details, my use is in Python mode and in emacs 29.1 (on Mac OS, but I don't think it matters here)

@jcs090218
Copy link
Member

Can you try the profiler and paste the result here? In theory, it shouldn't be slow. 🤔

Thank you!

@jcs090218 jcs090218 added the question Further information is requested label Apr 14, 2024
@vv111y
Copy link

vv111y commented Aug 19, 2024

fwiw I have a big performance issue in org-mode for 723K org file. I can open a separate issue if you want. Here is the profile:

         828  65% - ...
         710  56%  - ts-fold-indicators--render-window
         710  56%   - if
         710  56%    - progn
         710  56%     - let
         710  56%      - save-current-buffer
         710  56%       - unwind-protect
         710  56%        - progn
         710  56%         - condition-case
         710  56%          - progn
         710  56%           - ts-fold-indicators-refresh
         710  56%            - if
         710  56%             - progn
         710  56%              - if
         710  56%               - progn
         710  56%                - let*
         461  36%                 - if
         461  36%                  - progn
         400  31%                   - mapc
         399  31%                    - ts-fold-indicators--create
         399  31%                     - let*
         394  31%                      - if
         394  31%                       - let
         270  21%                        - ts-fold-indicators--create-overlays
         270  21%                         - let
         240  18%                          - save-excursion
         240  18%                           - while
         233  18%                            - setq
         233  18%                             - cons
         233  18%                              - ts-fold-indicators--create-overlay-at-point
         231  18%                                 let*
           3   0%                            + and
          30   2%                          + ts-fold-indicators--update-overlays
         124   9%                        + ts-fold-overlay-at
           5   0%                      + and
          61   4%                     ts-fold-indicators--remove-ovs
         249  19%                 - and
          89   7%                    tsc-query-captures
           7   0%                  + condition-case
           1   0%                  + cl-remove-if-not
         118   9%    Automatic GC
         351  27% + command-execute
          62   4% + timer-event-handler
          23   1% + redisplay_internal (C function)
           3   0% + clean-aindent--check-last-point

@jcs090218
Copy link
Member

I might need some work on the line comment mode, but I'm unsure if there is space for improvement. 🤔

@vv111y
Copy link

vv111y commented Aug 19, 2024

It's also just happened in elisp, my init.el file at 88k. Same profile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants