1 Reply Latest reply: Dec 13, 2007 2:36 AM by 807557 RSS

    Performance issues

    807557
      Hi,

      I'm benchmarking RTSJ memory allocation and GC and am a little surprised by the results.
      The bench consists of the following loop:
        • 1. Re: Performance issues
          807557
          Hi,

          I'm benchmarking RTSJ memory allocation and GC and am a little surprised by the results.
          Basically, the bench consists of the following loop:

          for(int i=0;i<500;i++)
          {
          String[] s = new String[10000];
          for(int j=0;j<10000;j++)
          {
          long before =
          s = Integer.toString(j);
          }
          }

          This code is supplemented with calls to System.nanoTime() and runs either directly from main() or from a RealtimeThread. The bench is ran on Solaris x86.

          When running the test using the "regular" JVM, s = Integer.toString(j); performs