Systems Research Group

Department of Computer Science, The University of Hong Kong

SRS

JESSICA2 PROJECT OVERVIEW

 

Figure 1.  An Overview of JESSICA2 System Architecture

Introduction 

Nowadays, new computing paradigm has shifted towards networked, mobile, and more secure computing environment. Such a new trend has brought a number of challenges, which require new ways to deal with increasingly complex patterns of interaction. As Java is now becoming widely accepted in the enterprise and is playing an important role in bringing benefits to mainstream users, it is worth studying the extension of Java’s computing capability to satisfy the new demands. In this research, we propose to develop a new Java virtual machine, named JESSICA2, based on our previous project JESSICA (“Java-Enabled Single-System-Image Computing Architecture”) to support parallel execution of multithreaded Java applications in a networked cluster environment. JESSICA2 can achieve thread mobility through a lightweight thread migration technique.  A cluster-aware Just-In-Time compiler will be incorporated in JESSICA2 for accelerating the execution speed.  With the new JIT compiler and thread migration support, Java threads that are executing computation hotspots can be migrated to other nodes to achieve more effective load balancing. JESSICA2 is implemented as a middleware at the virtual machine level that makes a cluster appear as a single, multi-processor machine to Java applications.  With JESSICA2, users can log onto any computing node and launch any Java application without modification of its Java code. Java threads can freely move across node boundaries and execute in parallel to achieve more scalable high-performance computing using clusters. 

Objectives

Java programming language incorporates threads and related concurrency constructs for realizing parallel execution without requiring special tools or support system. Concurrent programming in Java is much easier and more natural than in most other parallel languages or run-time supports, such as PVM, MPI or software DSM, which rely on data mobility to achieve parallel execution. To achieve some form of mobility, Java’s serialization allows the programmer to capture an object, convert it to a bytestream, and move it to a different virtual machine on local or remote nodes and reinitialize with the same state. While threads in Java are objects (java.lang.Thread), they are not serializable. Thus, multi-threaded Java applications can only be executed in a single machine with limited execution parallelism bounded by the number of CPUs in the machine. Since the Java multi-threaded programming has been widely accepted and used in modern applications, it is worth studying the extension of Java’s capability for parallel computing and other types of mobility.

In our research, we will build a distributed Java Virtual Machine with the support preemptive thread migration on a PC cluster for parallel execution of multithreaded Java applications. The thread migration subsystem will be coupled with a cluster-aware Just-In-Time compiler to accelerate the execution speed and achieve thread mobility. With JESSICA2, multi-threaded application can extend its execution across the entire cluster. All threads running among the cluster nodes would share all the resources that each thread has created or allocated, and they see the underlying cluster as a single computing system with multiple processors – single system image. Our ultimate goals are to maximize parallelism, to minimize load imbalance, and to achieve high-speed execution of real-life Java programs on a large-scale cluster.  The following issues will be addressed in JESSICA2 :

(1) Light-weight thread migration: JESSICA2 will support preemptive thread migration which allows a thread to freely move between machines during its execution.

(2) Building a global heap: In traditional Java Virtual Machine, all threads share a single heap for data accesses. To provide the same support in JESSICA2, we need to build a global heap that is accessible by all distributed Java threads. Any update made to the shared objects stored in the global heap should be protected by lock and unlock primitives to comply with the Java memory model. A distributed fine-grain locking mechanism is required to synchronize the object accesses in the distributed environment with minimum cost.

(3) Cluster-aware Just-In-Time compiler: To improve Java program's performance, a Just-in-Time (JIT) compiler will be incorporated in JESSICA2.  This requires the extension of the existing JIT compiler functions to support Java thread migration. 

(4) Preprocessing module for detecting object sharing: Java stores all objects in the heap and it is costly to synchronize the accesses on the objects stored in the heap. To reduce the cost incurred by the global heap accesses, a Java code analysis module can be designed to intelligently move the non-shared objects from the heap to the thread’s local storage. 

(5) Dynamic load balancing: The dynamic load balancing solution should be able to determine the number of nodes that will result in the greatest speedup and minimize the load imbalance by adjusting the number of threads per node. Load balancing becomes complicated when all objects are distributed among the cluster. The execution time of the thread also depends on object’s location.

(6) Transparent I/O Redirection:  Support of thread migration only makes sense if the threads continue to see their devices and their files after migrating to another node. A transparent I/O redirection service is required in JESSICA2.

  JESSICA2 will be developed based on our previous JESSICA project. The new system will be constructed at the middleware level on a cluster of standard PCs. This approach does not require any modification to the underlying operating system or to the Java applications running on top. It guarantees portability and compatibility with existing Java applications.

Java is becoming ubiquitous in the enterprise and is playing important role in bringing benefits to mainstream users. The enhancement of Java’s thread mobility with the support of JIT technique for execution acceleration is definitively of great value for making Java an all-pervasive, cross-platform solution for parallel and distributed high performance computing.  

 

C.L. Wang. Dec.. 15, 2005