On Thursday, 19 September 2013 at 17:21:16 UTC, Andrei Alexandrescu wrote:
On 9/19/13 6:05 AM, PauloPinto wrote:
In java, all classes are dynamically loadable, and most functions are
virtual. This is a deal breaker for the AOT.

Wrong. The Java AOT compilers that target embedded systems produce
static binaries.

That's not wrong. Java AOT compilers usually (or at least last time I looked) make it clear they support no dynamic loading/invocation etc. so in a sense they don't support 100% of Java.

You have not looked for way too long it seems. Our JVM with AOT compiler passes the official compliance tests (Java Compatibility Kit), which includes reflaction/invocation tests. Of course, if the class being loaded dynamically was known at compile time, it will resolve to the precompiled image, otherwsie, a JIT compiler kicks into action. GCJ has an interpreter serving the same purpose.

We even went a step further and created an interesting technique that enables you to reduce application download size and disk footprint by omitting the unused parts of the Java platform:

http://www.excelsior-usa.com/java-download-size.html

In order to remain spec compliant, the runtime is capable of downloading the omitted on demand. However, for sample apps that you can download from the above URL, there was not a single such download ever.

Reply via email to