Anchor(run_faster)>>I have just compiled and benchmarked my Java application and it seems to be running slower than than XXX JIT JVM. Is there anything I can do to make it go faster?
A few things: • If your programs allocate many small, short lived objects, the heap could be filling and triggering GC too regularly. Try increasing the initial and maximum heap sizes as per 5.5 How do I increase the runtime’s initial and maximum heap size? • RE – array accesses. We have sub-optimal runtime checking code, and the compiler is still not so smart about automatically removing array checks. If your code is ready, and it doesn’t rely on them, try compiling with –no-bounds-check. • Try static linking. On many platforms, dynamic (PIC) function calls are more expensive than static ones. In particular, the interaction with boehm-gc seems to incur extra overhead when shared libraries are used. • If your Java application doesn’t need threads, try building libgcj using –enable-threads=none. Portions of the libgcj runtime are still more efficient when single-threaded.
Related Questions
- Anchor(run_faster)>>I have just compiled and benchmarked my Java application and it seems to be running slower than than XXX JIT JVM. Is there anything I can do to make it go faster?
- Why do I get the "The application failed to initialize properly" or "MSCOREE.DLL was not found" error message when running the compiled program?
- Anchor(prog_cpp)>>Is it possible to invoke GCJ compiled Java code from a C++ application?