Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-dev] CDTProject creation scalability issue

Hi,
 
In java I programmatically created 800 managed CDTProjects in a UMLDevelopment workspace.
I noticed that the amount of heap memory required was approximately 700 MB.
I then closed the eclipse workspace and launched the eclipse application which opened this workspace again. This workspace still contained those open 800 CDT managed projects but did not consume 700MB but only about 150 MB.
Using the YourKit profiler I realised that there were a number of possibly extraneous objects that lay around during the creation of the cdt projects which included...
CfgProxyCache, CProjectDescription,MapProxyCache,CBuildSettingsCache,CConfigurationDescriptionCache,CFolderDescriptionCache,CLanguageSettingCache and above all the InternalXmlStorageElement.
So following are my questions...
1. Has anybody attempted to test Scalability on the new CDT4.0 and see how large a memory foot print it consumes.
2. Assuming that my application has next to no memory leaks, is there any reason why the workspace that creates the 800 projects should have such a large memory footprint, and when that eclipse workspace is restarted those 800 projects use siginificantly less memory.
3. Last but not the least, is there a way to release the cache and other temporary objects that might be the sideeffect of creating the CDTProjects ? I am looking for some free() , release() or some such api call that does not destroy the projects or purge its configuration, but cleans up all the temporary data structures which presumably consume all this large amount of memory.
 
Some of the call to the CDT4.0 API that I required:
 
ManagedBuildManager.createBuildInfo()
CoreModel.createProjectDescription()
CCorePlugin.createCDTProject()
ManagedBuildManager.createManagedProject()
ManagedCProjectNature.addManagedNature()
ManagedCProjectNature.addManagedBuilder ()
IManagedProject.createConfiguration()
ManagedBuildManager.saveBuildInfo()
CoreModel.setProjectDescription()
 
As a note the projects are created in a WorkspaceRunnable to prevent notification to listeners.
Any thoughts might be appreciated.
 
Cheers,
-RB

Back to the top