|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
August 7th, 1997
Updated: AUGUST 7th, 1997
JVM Showdown Now that Java has been officially proclaimed the Next Big Thing, every company is making sure that Java applets run best on their system. While the Mac world got a late start on the Java revolution (and is finally catching up with the Windows and Unix worlds' support for the latest Java standard, version 1.1.3), there are now many different Java environments available for Macintosh browsers. JVM? JIT? In a standard JVM, each Java instruction is converted into a native instruction and then forgotten. If this instruction is in a loop (and in a typical program, there are lots of loops), it could be converted millions of times. A JIT converts the Java instruction into a native instruction and then remembers it. This saves the overhead of each conversion after the first time the instruction is seen, and as the chart shows, it certainly makes a difference. So, if JITs are so much better, why did anyone release a standard JVM? Writing a good JIT takes a lot of time, and in today's computer industry, you need to get a product out quickly if you want it to make a splash. Sun needed to get Java released. Although Java was designed with the JIT concept in mind, they released the much simpler standard JVM so people could start experimenting with Java sooner. It is also easier to make a debugger work with a standard JVM, which makes programmers happy. Now that Java has past its second birthday, virtually everyone has converted to JITs for end users, while developers will use a standard JVM for debugging and a JIT for testing code performance. Since writing a JIT can be complicated, companies have been licensing JITs from Java compiler writers instead of creating their own. While Microsoft wrote its own JIT for WinTel boxes, they partnered with Mac compiler giant Metrowerks for their Mac Java support. Netscape used their own port of Sun's JVM in the Mac and Unix release of Navigator 3.0.1, but switched over to Symantec's JIT with the release of version 3.0 for Windows and version 4.0 for Macintosh. Apple originally planned to follow a similar path with Macintosh Runtime for Java (MRJ). Apple licensed Roaster's Java technologies, but then decided to develop a Java environment in-house and keep the Roaster code for an emergency backup. (MRJ is the JVM for Cyberdog, and can be used by any Macintosh application which supports Apple's JManager programming interface. Microsoft supports MRJ in Internet Explorer as an alternative to its own JVMs.) Java Versions Over the last several months, the state of Just-In-Time compilers on the Mac has improved markedly. There are now release-quality JITs available in Java environments from Apple, Metrowerks, Symantec, Netscape, Microsoft, and Roaster. While these JITs vary in terms of stability, most of them are capable performers for everyday use. Apple's own Java strategy is progressing nicely. There are three different JVMs available from Apple. MRJ 1.0.2, which ships with Mac OS 8, implements a standard Java 1.0.2 JVM. MRJ 1.5 was released in late July. Like MRJ 1.0.2, it also supports Java 1.0.2. However it includes numerous bug fixes and performance improvements, including an optional JIT for PowerPC Macs. Finally, Apple has released MRJ 2.0d2 to developers. This release finally implements (incompletely) Java 1.1.1, but its JIT has been delayed for a future release. MRJ 2.0d2 does include Sun's javac Java compiler. Later releases promise to include other standard Java development tools. If Apple does in fact release the final version of MRJ 2.0 with all of these tools, it will mark Apple's first giveaway of programming tools since the early versions of HyperCard. The public alpha of MRJ 2.0 is due in August and the final MRJ 2.0 should be released sometime following. While it's nice that Apple is catching up, the fact remains that the MacOS is seriously behind Windows in the realm of Java development. Apple has taken steps to make sure that this does not happen again. For the development of Java 1.2 (due out in December), Sun and Apple have agreed to intersperse their Java releases. As Sun finishes a release (development, alpha, or beta), Apple's Java team will get the source code and release the Mac version. Furthermore, Sun has lent Javasoft programmers to Apple to work on MRJ with Apple's own engineers. This plan should ensure that the Mac release of Java 1.2 will coincide with the release for Windows and Solaris. Third-party Mac Java developers have announced their own plans for Java 1.1.3 support. Metrowerks CodeWarrior Pro 1 ships with beta-quality support for Java 1.1.1. An online update to a more-stable Java 1.1.3 release is expected very shortly. Roaster Release 4 will have Java 1.1.1 support; Roaster's full plans for future Java support will be revealed at MacWorld Boston. Symantec has decided to cast its lot with Apple; future versions of Cafe and Visual Cafe will rely on MRJ for a 1.1.1-compliant JVM. CaffeineMarks The Tests
Loop Logic Method Graphics Image Dialog How did they do?
* - Did not successfully compete test These tests were run on a PowerBook 1400c/133, with 16M of RAM (RAM Doubler 2 set to triple RAM), 128K L2 cache, 1G hard drive, and Mac OS 8. While the changes in CaffeineMark have significantly reduced the gap between the performance of the JITs and the standard virtual machines, it is clear that a JIT provides significant improvement. Apple's MRJ 1.5 JIT, running within the Apple-supplied Apple Applet Runner is far and away the best performer. Bug fixes in MRJ 1.5 now allow it to be run correctly within Internet Explorer, and as can be expected, performance is significantly slower inside a browser rather than standalone. Even with the slowdown, MRJ 1.5 is faster than any other JVM embedded in a WWW browser. However, the biggest surprise is the complete failure of the Microsoft/Metrowerks VMs (JIT and standard) in MSIE 3.0.1 when run under Mac OS 8. Despite repeated attempts and installations, we were unable to get the CaffeineMark 3.0 tests to complete. During either the Graphics or Image test, the browser would always quit with an error of either type 2 or type 3. Since these virtual machines are nearly identical to the ones included with CodeWarrior Pro 1--and CodeWarrior Pro 1 had no problem completing these tests--the bug must be linked to something in the MSIE 3.0.1 browser itself. Luckily for Microsoft, MRJ 1.5 worked fine, and for the adventurous, the preview release of MSIE 4.0 was able to complete the tests with its new 1.1.3 JVMs. Microsoft, which had been championing its JIT from Metrowerks as the performance leader, finds itself in an interesting position. Their current release (3.0.1) is severely broken when used with Mac OS 8, but the preview release (4.0) has very good performance and the only Java 1.1.3 support on the Mac. Their JIT bests the MRJ JIT (when used with MSIE 3.0.1) in 4 out of the 9 categories, including a trouncing in the logic category, but it is still slower overall. Since MSIE 4.0 is still in early release, it's likely that Java performance will continue to improve in later versions. Netscape, which has aligned itself very closely with the Java revolution, is in serious trouble. Its JIT delivers only 55% of the performance of MRJ 1.5 when MRJ is run inside of MSIE 3.0.1. Since, Navigator does not support JManager, it cannot take advantage of the speedy MRJ 1.5 JIT. If Netscape intends to provide a viable Java option on the Mac, it will need to either support MRJ or improve its own JIT in a hurry. Roaster's performance is very exciting. While there's nothing spectacular about the performance of Roaster's standard JVM, the JIT is easily the fastest available for the Mac. However, there have been problems with the Roaster JIT's stability (see below). Furthermore, both the JIT and the standard JVM can only be used in conjunction with the stand-alone Roaster Runner application. Metrowerks' JIT and JVM are in the same boat, as the only way to invoke either one is by using the less-than-spectacular Metrowerks Java application. Symantec's Visual Cafe 1.0.1 is a so-so performer and its Java environment is equally unimpressive. It comes with an unremarkable applet/application runner which is nearly identical to the Sun AppletViewer. The graphic performance of all of the tested VMs is poor in general, due to the inferior video controller in the PowerBook 1400. Desktop Macs with their much faster video boards will have much better video scores. However, the video benchmarks do not benefit as much as CPU-bound tasks from a JIT, so they will continue to remain a limiting factor in Java performance as JVMs continue to mature. What about stability? During testing, each VM would display some fonts and windows slightly differently. Some VMs draw the menus inside the CaffeineMark window while others would append the menus onto whatever menus were currently on the menubar. It's hard to judge which VM is acting correctly when each one acts differently. This is the biggest problem facing Java today. If an applet doesn't seem to play correctly with one virtual machine, try using a different one to see if the display problems go away. Another part of the problem is that it's hard to evaluate stability with the current crop of publicly available applets, since many are too simple to stress a JVM. These problems should disappear with time, as Java continues to mature as a language and environment and the various VM makers agree on conventions. A few months ago, there was only JIT in final release for the Mac: the one included with Internet Explorer 3.0.1. Now, there are four. The best choice for Mac users is clearly MRJ 1.5, but it will be interesting to see what Microsoft and Metrowerks ship in the upcoming months. In conclusion All information on the base system and the test details are from Pendragon Software WWW site and are Copyright 1996-1997, Pendragon Software. For more information on the CaffeineMark(tm) benchmark, take a look at Pendragon's WWW site.
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||