This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Performace guidlines (tipps)?
- From: Bryce McKinlay <bryce at waitaki dot otago dot ac dot nz>
- To: Clemens Eisserer <Linuxhippy at web dot de>
- Cc: java at gcc dot gnu dot org
- Date: Thu, 01 Aug 2002 15:35:25 +1200
- Subject: Re: Performace guidlines (tipps)?
- References: <3D4866EB.2080605@web.de>
Clemens Eisserer wrote:
I want to write some gnu-apps which should be primary optimizied for gcj.
Are there some performance tipps whats better and faster? Are there
somewhere written guidlines avaible?
For the most part the same performance guidelines you apply to regular
Java code should be applied to GCJ. In particular you should try to
avoid unneccessary synchronization and avoid creating too many
short-lived objects, instead re-using existing ones wherever possible.
I'm currently using gcj-3.0.4. Will an upgrade enhace performance over
20%?
You should find that 3.1 and up have improved performance over 3.0.x, it
probibly depends on your app exactly how substantial the difference is.
one example:
is this better:
class c;
while(n>m)
{
c=new class();
}
or is it better to create the "class c;" in the loop.
It should make no difference.
regards
Bryce.