A performance evaluation of adm package


The performance of applications with 50 awt-based or swing-based CDEV beans are evaluated on a NT workstation. The results shows that the awt-based CDEV beans are 3 times faster than the swing based CDEV bean. The Just In time compiler (JIT) improved the performance 30% to 50%.


The adm package is a java library used to build Graphical User Interfaces for the control system through the cdev interface [1]. There are various control and monitor widgets in the package. These widgets can be used in the application or applet as java beans. Each bean will monitor or control different devices in the control system. Since the values in the control system change in a certain speed, it is is necessary to conduct a performance evaluation of these adm widgets. We hope these results will provide some guidelines for the user.

Test system set up

Six cdev widgets, COval/CRect, CText, CBar, CMeter, CLabel and CTextField are included in the test. Each test program contains 50 similar beans connected to different devices. The color mode in COval/CRect, CText, CBar and CMeter tests are set to CLRMOD_ALARM. The label style in CBar and CMeter are set to LABEL_ALL.

The CPU usage is measured using Microsoft Window NT Task Manager. The results are recorded 1 minutes after the program started.

In the Win32 version of the JDK1.2.2 used in this test, the JIT is invoked by default. The JIT compiler can be disable by setting the java.compiler property to NONE [2]. The performance evaluation are conducted using the java with and without the JIT compiler.

Test results

Figure 1 shows the awt-based widgets are twice as fast as the swing-based widgets when using the JIT compiler. To handle 100 updates per second (2 updates per second for 50 components) it only requires 10~18 %CPU time if the awt-based beans are used. It needs twice much CPU time if swing-based beans are used.

Figure 1

Figure 2 plots CPU time to run the application containing 50 CDEV widgets without the JIT compiler. In this case the swing-based bean require 3 times more CPU than the awt-based bean. The JIT compiler reduces the time to run the swing-based widget application by 50% and awt-based widget application by 30%.

Figure 2