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

Org: optimize #3611

Merged
merged 5 commits into from
Dec 27, 2022
Merged

Org: optimize #3611

merged 5 commits into from
Dec 27, 2022

Conversation

masatake
Copy link
Member

@masatake masatake commented Dec 27, 2022

The Org parser is incredibly slow.

The original:

[yamato@dev64]~/var/ctags-github% ./ctags --totals /home/yamato/var/emacs/doc/misc/org.org
1 file, 22606 lines (802 kB) scanned in 98.8 seconds (8 kB/s)
625 tags added to tag file
625 tags sorted in 0.00 seconds
longest tag line = 127

With this pull request:

[yamato@dev64]~/var/ctags-github% ./ctags --totals /home/yamato/var/emacs/doc/misc/org.org
1 file, 22606 lines (802 kB) scanned in 0.6 seconds (1291 kB/s)
624 tags added to tag file
624 tags sorted in 0.00 seconds
longest tag line = 127

It becomes 150% faster with this pull request.

BTW, this parser doesn't fill scope fields.

@masatake
Copy link
Member Author

masatake commented Dec 27, 2022

However,... one tag is lost with this change.


I inspected this. The missing one should not be tagged.

@codecov
Copy link

codecov bot commented Dec 27, 2022

Codecov Report

Base: 82.84% // Head: 82.84% // Increases project coverage by +0.00% 🎉

Coverage data is based on head (d068172) compared to base (12ff207).
Patch coverage: 0.00% of modified lines in pull request are covered.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3611   +/-   ##
=======================================
  Coverage   82.84%   82.84%           
=======================================
  Files         223      223           
  Lines       54280    54279    -1     
=======================================
  Hits        44966    44966           
+ Misses       9314     9313    -1     
Impacted Files Coverage Δ
optlib/org.c 0.00% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
Signed-off-by: Masatake YAMATO <yamato@redhat.com>
Signed-off-by: Masatake YAMATO <yamato@redhat.com>
Signed-off-by: Masatake YAMATO <yamato@redhat.com>
…es starting from "#" earlyer

Signed-off-by: Masatake YAMATO <yamato@redhat.com>
@masatake
Copy link
Member Author

I found the Org parser extracts many noises. It may be rewritten more line-oriented way.

@masatake masatake merged commit 2fc641e into universal-ctags:master Dec 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant