Bug 27925 - Openable.hasChildren is slow
Summary: Openable.hasChildren is slow
Status: RESOLVED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 2.1 M4   Edit
Assignee: Jerome Lanneluc CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance
: 27924 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-12-09 05:28 EST by Adam Kiezun CLA
Modified: 2002-12-16 12:21 EST (History)
0 users

See Also:


Attachments
expanding/collapsing nodes in packeage explorer 2 (9.58 KB, text/plain)
2002-12-09 05:29 EST, Adam Kiezun CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Adam Kiezun CLA 2002-12-09 05:28:31 EST
quite often i see Openable.hasChildren consume a lot of time on various 
operations
Comment 1 Adam Kiezun CLA 2002-12-09 05:29:48 EST
Created attachment 2721 [details]
expanding/collapsing nodes in packeage explorer 2

like expanding/collapsing nodes in the package explorer
where it consumes almost 67%
Comment 2 Philipe Mulet CLA 2002-12-09 05:58:46 EST
It has to do some work: i.e. open the corrresponding resource and expand it to 
find out that it has some children.

Maybe we could always answer true on some kinds of resources (like JARs)...

Do you have particular scenarii where it specially takes some time ?
Comment 3 Adam Kiezun CLA 2002-12-09 10:32:49 EST
the scenario is expanding a node in the package expolorer (project or source 
folder)
Comment 4 Adam Kiezun CLA 2002-12-09 10:33:04 EST
*** Bug 27924 has been marked as a duplicate of this bug. ***
Comment 5 Jerome Lanneluc CLA 2002-12-09 12:03:34 EST
Adam, how do you take the measure? When I expand a node, I don't have time to 
start and stop the CPU profiler. Do you have a test case where expanding a node 
takes more than half a second?
Comment 6 Adam Kiezun CLA 2002-12-09 12:58:27 EST
try Jeff's bigworkspace
start profiling before expanding
stop after expanding
Comment 7 Jerome Lanneluc CLA 2002-12-10 05:02:48 EST
When doing so, I see it takes 165ms in AbstractTreeViewer.handleTreeExpand() to 
expand the tree on the 'org.eclipse.core.tests.resources' node. Which node did 
you chose to get 1003ms in AbstractTreeViewer.handleTreeExpand()?
Comment 8 Adam Kiezun CLA 2002-12-11 07:52:37 EST
try expanding org.eclipse.swt
Comment 9 Jerome Lanneluc CLA 2002-12-16 12:21:26 EST
I now see 187ms spent in hasChildren when expanding org.eclipse.swt.

Closing.