Sir_Sword
July 22nd, 2014, 08:42 PM
These days Java is a bit of an odd duck. It's nice and fast because when you run a Java program it gets compiled to native on your own machine, but it also uses a lot of memory because of the JVM and self-contained Java applications can be quite large if you package the Oracle JRE with them because you have to include almost the whole JRE.
But Java has lots of other options too. Alternate JVMs, such as OpenJDK, other JVMs which are much smaller than the Oracle JVM and can be distributed with a Java application to make it self-contained, and programs to compile Java to native so you can distribute them in native format. This is all third-party software.
Then there's the world of Android. Up until now Android has used the Dalvik JVM which, like the standard JVM, compiles the Java bytecode to native when the Java app is run. However Dalvik is going to be replaced by Android Runtime, or ART, which is a new JVM that compiles the bytecode to native when the app is installed instead of when the app is run, so when the app is actually ran it runs from native directly every time.
I was wondering, do any of you think desktop Java will follow a similar path? Do you think it will ever include a mechanism so that Java applications are compiled at install time, or perhaps at the first run, and then the native binary is used every time going forward instead having to recompile it again each time?
For that matter, do you think Oracle will ever create a version of the JRE that can intelligently and dynamically detect which libraries are needed for a Java application, and allow people to create self-contained applications that only include those parts which are actually needed instead of almost the whole thing?
But Java has lots of other options too. Alternate JVMs, such as OpenJDK, other JVMs which are much smaller than the Oracle JVM and can be distributed with a Java application to make it self-contained, and programs to compile Java to native so you can distribute them in native format. This is all third-party software.
Then there's the world of Android. Up until now Android has used the Dalvik JVM which, like the standard JVM, compiles the Java bytecode to native when the Java app is run. However Dalvik is going to be replaced by Android Runtime, or ART, which is a new JVM that compiles the bytecode to native when the app is installed instead of when the app is run, so when the app is actually ran it runs from native directly every time.
I was wondering, do any of you think desktop Java will follow a similar path? Do you think it will ever include a mechanism so that Java applications are compiled at install time, or perhaps at the first run, and then the native binary is used every time going forward instead having to recompile it again each time?
For that matter, do you think Oracle will ever create a version of the JRE that can intelligently and dynamically detect which libraries are needed for a Java application, and allow people to create self-contained applications that only include those parts which are actually needed instead of almost the whole thing?