Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Swing Performance 512 MB vs. 1.5 Gb  RSS feed

 
Isaac Hewitt
Ranch Hand
Posts: 191
Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have written my own Swing windowed program which compresses and decompresses files using the ZIP extension.

I have written and tested the program on both a laptop and PC that have identical RAM and processor specs. The RAM on both is 1 and a half gigabytes. The program is as fast as any of my other programs which are written in C++. I tested its recursive search capabilities against the Windows XP search function, and my program can search for and find every file ending in ZIP on my hard drive as fast or faster than Windows. All of the zipping and unzipping functions are as fast as any of the leading Zip programs on the market.

Unfortunately, when the same program was installed on a friend's laptop with only 512 megabytes of RAM, the search capabilities were less than stellar and in fact quite dismal. This person also has 18 gigabtyes of files to search through. The first two computers above have no more than 9 gigabytes of files to search through.

The program keeps searching without stopping.

Just one last note. The zipping and unzipping functions on the slower laptop are not much slower and they fuction perfectly. It is just the disk scanning part of it that fails to deliver.

Does anyone with experience in Files have any advice on how to make it search more effeciently or am I missing something in my search methods. I can provide the code. Or should I just rewrite the prgram in C++ or C#?
Perhaps it is a memory issue although I have used the Profiler in NetBeans and the memory consumption does not seem to keep increasing that much.

Thanks.
 
Stefan Wagner
Ranch Hand
Posts: 1923
Linux Postgres Database Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you start your program with the -Xmx -switch?
If not - having or not having much RAM shouldn't affect its performance.

Did you compare the java-versions?
What's about differences of the drives - in core hardwareperformance, and perhaps dma-settings?

I don't know how you set and inspect harddrive-parameters on windows, but the bios could be a starting point.

And perhaps the filesystem might do a differnce.
Allways ntfs or vfat?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!