Community
Participate
Working Groups
Build Identifier: CDT: 20100917-0705, Eclipse platform: 3.6.1.r361_v20100909-9g..etc As I develop over the course of the day, my heap starts small (~500M), and over the course of the day, it blows up to use all of it (-Xmm 2500m.) Eclipse becomes more & more unresponsive, by the end, it takes 3-4 seconds to respond to a mouse click or key-press. I did a heap analysis (screen shots attached), and it appears to be codan code-analysis, and some weak-hash-map that is used inside it. Reproducible: Always Steps to Reproduce: 1. start eclipse. it happens w/ both -Xmm 2048m, and also -Xmm 2500m 2. work all day, watch eclipse's response time to key presses & mouse clicks get worse (3-4 seconds) 3. note that I'm not building within Eclipse, so if Eclipse builds up some map of code-errors & doesn't erase them until the next make... well, I'm using external makefile & console to build, so that map will exist for ever. 4. Also note that restarting Eclipse gives me a small clean heap, so that's my current workaround.
Created attachment 180880 [details] screenshot of heap analysis. Piechart of biggest objs.
Created attachment 180881 [details] heap analysis's shortest path view of large objs
Created attachment 180882 [details] heap analysis's accumulated objs view
This is easily reproduce-able for me, so I'm happy to try things if a developer wants to get in touch. Thx, Mike
Humm, still need to investigate some more but... WeakHashMap<IASTFunctionDefinition, IControlFlowGraph> cfgmap IControlFlowGraph can contain a node with strong reference to the same IASTFunctionDefinition as the key, for example through AST parents. Mike, is it seen while always working on the same file?
Thanks for analysis! There is a bug where cache is not cleaned when new files are opened. Also "weak" part of the hash does not seems to work. Anyway fixed. Also added paranoia mode (don't keep more than 20 elements) As workaround disable all return related checkers
*** cdt cvs genie on behalf of elaskavaia *** Bug 327779 - fixed cash items leakage [*] AbstractIndexAstChecker.java 1.13 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/codan/org.eclipse.cdt.codan.core.cxx/src/org/eclipse/cdt/codan/core/cxx/model/AbstractIndexAstChecker.java?root=Tools_Project&r1=1.12&r2=1.13 [*] CxxModelsCache.java 1.5 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/codan/org.eclipse.cdt.codan.core.cxx/src/org/eclipse/cdt/codan/core/cxx/model/CxxModelsCache.java?root=Tools_Project&r1=1.4&r2=1.5
Did you mean clearCache instead of clearCash?
did I wrote Cash? I guess I typing what I thinking :)
Created attachment 181691 [details] Cash to cache (In reply to comment #9) > did I wrote Cash? I guess I typing what I thinking :)