Bug 399783

Summary: C++ code parsing is slower than compilation
Product: [Applications] kdevelop Reporter: Eugene Shalygin <eugene.shalygin+bugzilla.kde>
Component: Language Support: CPP (Clang-based)Assignee: kdevelop-bugs-null
Status: REPORTED ---    
Severity: normal CC: igorkuo
Priority: NOR    
Version First Reported In: git master   
Target Milestone: ---   
Platform: Other   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=464198
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Eugene Shalygin 2018-10-14 10:33:33 UTC
Parsing in KDEvelop is extremely slow most of the times. Only cleaning session cache and restarting make it reasonably quick again.

STEPS TO REPRODUCE
1. Load a project of size > 1e5 LOC
2. Select "Reload" in the project context menu
3. Open the parsing progress bar. 

OBSERVED RESULT

Parsing of each file takes about 10 seconds.

EXPECTED RESULT
Parsing takes not longer than compiling the same project (i.e. it has to be ~10 times faster).


SOFTWARE VERSIONS
(available in About System)
KDE Plasma Version: 5.14.80
KDE Frameworks Version: 5.51.0
Qt Version: 5.11.1

ADDITIONAL INFORMATION
Changing "Compiler for paths" in the project settings sometimes help to recover the parsing speed.
Comment 1 Eugene Shalygin 2018-10-15 10:41:17 UTC
> 2. Select "Reload" in the project context menu

Or make a branch switch which updates many files.
Comment 2 Eugene Shalygin 2018-10-16 13:15:17 UTC
Changing C++ standard in the project settings results in the slow parsing too.
Comment 3 Justin Zobel 2022-12-01 04:34:52 UTC
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 4 Eugene Shalygin 2022-12-01 08:18:27 UTC
It is still a problem. CLang-based code model in Qt creator, for example, parses faster than it takes to compile the code.