Review Request: Do not perform background parsing when there are projects in state of loading
Dmitry Risenberg
dmitry.risenberg at gmail.com
Tue Feb 22 23:11:15 UTC 2011
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/100688/
-----------------------------------------------------------
(Updated Feb. 22, 2011, 11:11 p.m.)
Review request for KDevelop.
Changes
-------
Handle project loading abortion.
Also change default argument to ModificationRevision. The comments previously referred to SmartInterface and are misleading regarding MovingInterface (see updated test). The wrong argument did not match actual revision and caused some DUchain contexts to be deleted as "out of date" on exit.
Summary
-------
In BackgroundParser, before running actual parsing, check whether there are projects in state of loading. If there are, wait until they are loaded completely. Without this, initially open files may be parsed two times: first as open files, second as members of a project. In the second case the list of include paths may be different, and that may cause some recursive re-parsing. Also differet sets of defines may cause re-parsing, though it wasn't tried.
Diffs (updated)
-----
language/backgroundparser/backgroundparser.h a8a7b06
language/backgroundparser/backgroundparser.cpp 28bdfee
language/editor/modificationrevision.h d1d54ae
shell/project.cpp 7b2bdf6
shell/projectcontroller.cpp 9b6c96f
shell/tests/shelldocumentoperationtest.cpp 99e5855
Diff: http://git.reviewboard.kde.org/r/100688/diff
Testing
-------
Initial testing time varies greatly from launch to launch, so could not estimate the influence on average parsing time. However, the worst-case parsing time (when open files are parsed before their projects are loaded and then reparsed) does decrease.
Thanks,
Dmitry
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20110222/ee3baf14/attachment.html>
More information about the KDevelop-devel
mailing list