I was reading published paper by Hiroshi Yamauchi & Mario Wolczko at Sun Microsystems Laboratories.
"Writing Solaris Device Drivers in Java"
It is quite interesting to know there is an effort to port the JVM embedded in the Solaris kernel. There system is based on the Squawk virtual machine.The Squawk virtual machine core is mostly written in Java. It has an interpreter, and a just-in-time compiler. The lower-level parts and the main loop of the interpreter are written in C, while the more complex instructions (such as those dealing with monitors) are implemented in Java.
They have created and tested a RamDisk Device Driver written in Java.
They performed the following simple performance measurements to compare the Java version of the driver to the C version.
The measurements were performed on a Sun E420R system with four 450MHz UltraSPARC II CPUs and 1GB of RAM, using Solaris 10 (Build 76).
1. Raw system call overhead We measured the time to call the close system call on the RAM disk device. Because the close function of the RAM disk driver is empty, the measurement yields the total overhead from the system call down to the device driver routine and back. We repeated the measurement ten times and computed the average time. The Java version took 4.48 microseconds whereas the C version took 3.84 microseconds, an overhead of 16.7%. The virtual machine was given 512 KB of heap.
2. Throughput We measured the time to copy a 1MB file within the RAM disk. This measurement should indicate the performance of the block I/O of the driver. We repeated the measurement ten times and computed the average time. The Java version took 178 microseconds and the C version took 63 microseconds. When a GC occurred during a copy, the Java version took 230 microseconds. The Java version took approximately 2.8 times and 3.8 times longer than the C version without and with a GC, respectively. The virtual machine was given 512 KB of heap. We believe the overhead in the Java version is mainly due to bytecode interpretation. The results are encouraging because the Squawk virtual machine we used was an early unoptimized version,with a just-in-time compiler in development.
But what I see is if Java based device drivers are developed then the same driver can be used for both SPARC and X86 platform without modification provided the JVM is ported to both SPARC and x86.And may be if the JVM is ported to Linux then same driver can be used in linux too.
If you want to get the PDF file for the technical details then you can get it from
http://research.sun.com/techrep/2006/smli_tr-2006-156.pdf
"Writing Solaris Device Drivers in Java"
It is quite interesting to know there is an effort to port the JVM embedded in the Solaris kernel. There system is based on the Squawk virtual machine.The Squawk virtual machine core is mostly written in Java. It has an interpreter, and a just-in-time compiler. The lower-level parts and the main loop of the interpreter are written in C, while the more complex instructions (such as those dealing with monitors) are implemented in Java.
They have created and tested a RamDisk Device Driver written in Java.
They performed the following simple performance measurements to compare the Java version of the driver to the C version.
The measurements were performed on a Sun E420R system with four 450MHz UltraSPARC II CPUs and 1GB of RAM, using Solaris 10 (Build 76).
1. Raw system call overhead We measured the time to call the close system call on the RAM disk device. Because the close function of the RAM disk driver is empty, the measurement yields the total overhead from the system call down to the device driver routine and back. We repeated the measurement ten times and computed the average time. The Java version took 4.48 microseconds whereas the C version took 3.84 microseconds, an overhead of 16.7%. The virtual machine was given 512 KB of heap.
2. Throughput We measured the time to copy a 1MB file within the RAM disk. This measurement should indicate the performance of the block I/O of the driver. We repeated the measurement ten times and computed the average time. The Java version took 178 microseconds and the C version took 63 microseconds. When a GC occurred during a copy, the Java version took 230 microseconds. The Java version took approximately 2.8 times and 3.8 times longer than the C version without and with a GC, respectively. The virtual machine was given 512 KB of heap. We believe the overhead in the Java version is mainly due to bytecode interpretation. The results are encouraging because the Squawk virtual machine we used was an early unoptimized version,with a just-in-time compiler in development.
But what I see is if Java based device drivers are developed then the same driver can be used for both SPARC and X86 platform without modification provided the JVM is ported to both SPARC and x86.And may be if the JVM is ported to Linux then same driver can be used in linux too.
If you want to get the PDF file for the technical details then you can get it from
http://research.sun.com/techrep/2006/smli_tr-2006-156.pdf