A JVM (Java Virtual Machine) is an implementation of the specifications that SUN puts out to create a standard environment for running Java code. Each "Java enabled" browser out there has a JVM in it to run the applets, servlets, etc. However the vendor (Netscape, Internet Explorer, etc) has to write their own JVM that meets the SUN specifications. A JIT (Just In Time Compiler) is a tool to increase the performance of Java Applications. If the "interpreting" of the code is slowing things down, then you can use a JIT to actually compile the JAVA code on the fly to a machine specific version, which speeds things up.
"JavaRanch, where the deer and the Certified play" - David O'Meara
You can't access the JIT compiler - it's part of the JVM. The JVM uses it to compile the bytecode as it's read. Which is a shame really, I wouldn't mind having a good Java compiler, and I wouldn't think it would be that hard to make the JIT compiler stand-alone. I guess Sun don't want Java coders writing platform specific apps. Saying that, MS wrote the Windows JVM, so who knows. You can get Java compilers, but you have to pay for them. I was looking for free ones once, and GNU and a few other people are developing them, so that might be worth a look if that's what you want.
posted 19 years ago
If you want to see the JIT effect, write a very complicated algorithm heavy program with a lot of nested iterations in both C++ and Java. When the program is relative simple, the C++ program runs much faster (about twice) than Java. However, if the nested iteration goes more and deep, the Java program can run faster than C+++. See discussion in this thread here: http://www.javaranch.com/ubb/Forum34/HTML/000258.html Thanks! Roseanne Join our SCJD Study Group when certified
I have a problem. An IRC Client applet is running without problem on win98 or win95, but win2k and winME users have problems when the JIT Compiler is enabled in their browsers. No error in java console when JIT is enabled, but the irc server drops their connections with connection reset by peer. so what can be the problem? Or can I disable the JIT compiler for my applet? email answer is also good: firstname.lastname@example.org thx [more] Win ME users said: "JIT.DLL caused illegal op in kernel32" Can I disable JIT from the applet (only for my applet, not the whole JIT)?? Plz... [This message has been edited by Thomas Krasser (edited February 03, 2001).]