|
Re: improve performance of tree [message #461180 is a reply to message #461160] |
Mon, 19 September 2005 12:44 |
Eclipse User |
|
|
|
Originally posted by: kent.generatescape.com
try: treeViewer.setUseHashlookup(true);
also do you mean in you 1000-3000 nodes in one sub-node?
I have a big tree 50,000 nodes, but never 1000 nodes in one subnode,
normally only about 5 to 10, and I don't have a performance problem. However
there is an issue with like minded nodes, you might want to look at my
latest mail.
"Archana" <archana@yasutech.com> wrote in message
news:f6e2d378e395f91a084e2f60494b1cbb$1@www.eclipse.org...
> Hi, I have created a tree viewer that have over 100 parents and each node
> has 1000-3000 children. The performance is extremely slow. It takes about
> 2-3 minutes to expand the tree. How can improve the performance.
> Any suggestions/inputs on the problem?
>
> Thankz Archana
>
>
|
|
|
|
Re: improve performance of tree [message #461341 is a reply to message #461160] |
Wed, 21 September 2005 04:42 |
No real name Messages: 97 Registered: July 2009 |
Member |
|
|
"Archana" <archana@yasutech.com> wrote in message
news:f6e2d378e395f91a084e2f60494b1cbb$1@www.eclipse.org...
> Hi, I have created a tree viewer that have over 100 parents and each node
> has 1000-3000 children. The performance is extremely slow. It takes about
> 2-3 minutes to expand the tree. How can improve the performance.
> Any suggestions/inputs on the problem?
What do you add during expansion? Is it for file folders?
If you have performance problems, virtual tables do not help much.
It could be outside of SWT. For example, if you read file folders
and create node items, then reading file information will take
bulk of time. Try before and after;
tree.setRedraw(false);
.....
tree.setRedraw(true);
Within this block, adding 1000~3000 tab items per se should be donw
within a few second, probably less than a second. In addition, try to add
or
expand only it is needed, i.e., use lazy-evaluation methods.
Note that virtual tables can save Java Runtime resources, especially
heap memory space, if you have millions of entries. However you
need to know the number of elements and stable entry information.
Since your program will spend most of time getting that information,
virtual table may not give you much speed.
In a nutshell, use the setRedraw() and add expansion information wisely.
Also, optimize the real source of speed problem, which will be outside
SWT domain, e.g., IOs, database connections, etc.
Hope this will easy your problem.
Regards.
>
> Thankz Archana
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.02997 seconds