Herong's Tutorial Notes on JVM
Dr. Herong Yang, Version 3.00, 2007

JRockit JVM 8.0

Part:   1  2  3 

This chapter explains:

  • Installing JRockit JVM 8.0
  • Testing with LongWhile.java
  • Testing with LongSleep.java

Installing JRockit JVM 8.0

One of the JRockit developers saw my notes on JRockit 7.0 on the Web, and suggested me to try JRockit 8.0. So I downloaded the evaluation version of JRockit 8.0, and did a couple of quick tests.

To try JRockit 8.0, I went to http://commerce.bea.com/showallversions.jsp?family=WLJR. Then using my registered name and password, I got the download page. There, I selected WebLogic JRockit 8.0 SDK, then Microsoft Windows (32 bit). At the end of download process, I got jrockit-8.0-j2se1.4.1-win32.exe (35,864KB).

The installation process was straight forward by double clicking on the downloaded file. At the end, JRockit was installed at \local\bea\JRockit80_141_32.

To check the installation, I did the following in a command window:

\local\bea\JRockit80_141_32\bin\java -version
java version "1.4.1_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1_01)
BEA WebLogic JRockit(R) Virtual Machine (build 8.0-1.4.1_01-win32-CROSIS
-20030124-1058, Native Threads, Generational Concurrent Garbage Collecto
r)

There seems to be a Java compiler interface integrated in JRockit 8.0:

\local\bea\JRockit80_141_32\bin\javac AnyClass.java
error: cannot read: AnyClass.java
1 error

Another difference in 8.0 is that the Management Console server option is changed:

\local\bea\jrockit80_141_32\bin\java -version -Xmanagement
[JRockit] Management Server started on port 7090.
...

Testing with LongWhile.java

Here is my LongWhile.java I used before to test the previous version of JRockit:

/**
 * LongWhile.java
 * Copyright (c) 2002 by Dr. Herong Yang
 */
class LongWhile {
   public static void main(String[] a) {
      Runtime rt = Runtime.getRuntime();
      System.out.println(" Free memory: " + rt.freeMemory());
      System.out.println("Total memory: " + rt.totalMemory());
      while (true);
   }
}

Test 1: Running LongWhile with JRockit

I compiled LongWhile with the compiler command interface provided by JRockit, then launched it with JRockit JVM:

\local\bea\JRockit80_141_32\bin\java LongWhile
 Free memory: 66936968
Total memory: 77594624

On the Windows Task Manager:

Before running LongWhile:
   Performance tab:      CPU:   1%, MEM: 132032K

Once LongWhile started:
   Performance tab:      CPU: 100%, MEM: 230468K
   Processes tab - java: CPU:  99%, MEM:  10740K

10 minutes later: about the same.

So, everything looked normal. But one interesting area was that the memory usages reported by JRockit JVM and Windows Task Manager were very different: 77594K vs. 10740K.

Test 2: Running LongWhile with HotSpot

In order to compare with HotSpot, I repeated above test with J2SDK 1.4.1_01:

\local\j2sdk1.4.1_01\bin\java LongWhile
 Free memory: 1782304
Total memory: 2031616	

On the Windows Task Manager:

Before running LongWhile:
   Performance tab:      CPU:   1%, MEM: 132032K

Once LongWhile started:
   Performance tab:      CPU: 100%, MEM: 140960K
   Processes tab - java: CPU:  99%, MEM:   4716K

10 minutes later: about the same.

Obviously, the memory usage reported by HotSpot matched better with Windows Task Manager: 2031K vs. 4716K. The difference here reflected the memory usage of the JVM itself.

(Continued on next part...)

Part:   1  2  3 

Dr. Herong Yang, updated in 2007
Herong's Tutorial Notes on JVM - JRockit JVM 8.0