Find uses/rename is being painfully slow
apaku at gmx.de
Thu Feb 17 15:03:48 UTC 2011
On 17.02.11 17:54:48, Dmitry Risenberg wrote:
> 2011/2/17 Aleix Pol <aleixpol at kde.org>:
> > On Thu, Feb 17, 2011 at 3:09 PM, Dmitry Risenberg
> > <dmitry.risenberg at gmail.com> wrote:
> >> 2011/2/17 Milian Wolff <mail at milianw.de>:
> >> > afaik the problem is getting *all* uses to make the renaming correctly.
> >> > And
> >> > for that *all* project files are checked to be up2date. And this takes
> >> > time.
> >> > Long time.
> >> But why do we have to reparse everything? The project should have
> >> already been parsed on loading. I mean, if we do not reparse, what
> >> test scenario can give us a wrong result? Or is it so because there
> >> are different levels of parsing?
> >> --
> >> Dmitry Risenberg
> >> --
> >> KDevelop-devel mailing list
> >> KDevelop-devel at kdevelop.org
> >> https://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop-devel
> > By default most files besides the current one won't have all uses created so
> > you need to reparse those to make sure they all have the proper information.
> > Aleix
> Played with Eclipse a little more - it does no parsing on startup
> (just loads what is already parsed, I suppose), and when I call
> Rename, it does some quick checking and then outputs a preview of what
> is going to be changed. However, if I change a file outside Eclipse,
> it says that a file is out of sync and aborts the renaming.
> So the question is - can we check whether the file needs reparsing (by
> modification date or something) - i'm not familiar with DUChain
> format. If we can, then "reparse all" can be avoided by running
> background low-priority parsing when there is spare CPU.
The problem is (AFAIK and my duchain-info might be even more limited than
yours) that the parsing that KDevelop does when opening a project the first
time is not sufficient to generate the use-information. The reason that is
not done is because its slow, very slow and not necessary all that often.
Hence use-building is only done when necessary, which is what makes
You will get what you deserve.
More information about the KDevelop-devel