Revision 871478

Go back to digest for 19th October 2008

Optimization in Development Tools

David Nolden committed changes in /trunk/KDE/kdevplatform/language/duchain:

- Move the unloading/cleanup completely into a background-thread
- Do the cleanup in 2 phases. One "soft" phase, where no write-lock is held over the whole time.

This prevents the UI from blocking, the only problem is that it doesn't guarantee disk consistency.

Thus, after this phase, do the same again, this time with a complete write-lock.

We stop all parsing threads before the first phase, so the changes that happen are minimal.

Thus we only have to write very few data in the second phase, hold the write-lock for a very short time, thereby preventing the UI from blocking while waiting for a read-lock.

This fixes the annoying and very long UI lockups that happen time by time when a lot of parsing is going on, like parsing a whole project.

File Changes

Modified 2 files
  • /trunk/KDE/kdevplatform/language/duchain
  •   /duchain.cpp
  •   /duchain.h
2 files changed in total