Revision 904716

Go back to digest for 4th January 2009

Optimization in Development Tools

David Nolden committed changes in /trunk/KDE/kdevelop/plugins/languages/cpp:

- Implement an additional much easier and faster way of environment management, that does not do any tracking of macro-dependencies and such. Instead, it just recognized the header-guard, and always inserts the un-guarded version.
This creates a much cleaner structure to work with for refactoring and such, since every "#include ..." leads to an importing of the top-context for the include containing all its data, regardless of any header-guards.
Logically it makes a step away from seeing everything as a virtual translation-unit, to the actual "logical" structure.
The main advantage though is that _much_ less "virtual" proxy-contexts are created, especially for very large projects.
This means that less parsing has to be done, less space on disk is used, and there's generally much less duplication.
It isn't all that correct any more, but I haven't found a single case where this theoretical correctness had any influence.
This is meant to be an option, beside of "full" environment-management, but for now it's the default, since it works very good.

Everyone who has a very large project, and needed a lot of time to have kdevelop process it, should try again now.

File Changes

Modified 11 files
  • /trunk/KDE/kdevelop/plugins/languages/cpp
  •   /cpplanguagesupport.cpp
  •   /cppparsejob.cpp
  •   /cppparsejob.h
  •   /preprocessjob.cpp
  •   /preprocessjob.h
  •   /cppduchain/cpppreprocessenvironment.cpp
  •   /cppduchain/cpppreprocessenvironment.h
  •   /cppduchain/environmentmanager.cpp
  •   /cppduchain/environmentmanager.h
  •   /tests/test_cppcodecompletion.cpp
  •   /tests/test_cppcodecompletion.h
11 files changed in total