2 ms·
In theory. I've never actually tried Excelsior or any other AOT Java compiler, so I can't comment on that. What I do know is that Swift is free and has first-cl
by Cyph0n 10y ago
In theory. I've never actually tried Excelsior or any other AOT Java compiler, so I can't comment on that. What I do know is that Swift is free and has first-class support for AOT compilation.
- pjmlp 10y agoI think it was an error from Sun not to offer AOT in addition to JIT, but apparently they were religious against the idea, only offering it on the embedded JDKs. This could have made Java actually relevant on the desktop, ignoring for a second how clueless Sun was about doing good desktop libraries. However with Java 9 you will be able to use the new Java linker and create you own little VM + AOT startup code. So that coupled with the large Java eco-system is already good enough for many of us. Swift does compile to AOT today, but the tooling and libraries outside Apple platforms is almost insignificant, and only good enough for startups willing to bet on it.
- Cyph0n 10y agoThat Java 9 feature would definitely be amazing. I agree, Swift is nowhere near the maturity of the Java ecosystem.
- pjmlp 10y agoThe linker part is described in these JavaONE 2016 talks https://www.youtube.com/channel/UCdDhYMT2USoLdh4SZIsu_1g/search?query=linker https://www.youtube.com/channel/UCdDhYMT2USoLdh4SZIsu_1g/sea...
- Cyph0n 10y agoThanks for that. Are you aware of any numbers on the size savings you get for a typical app using jlink?
- pjmlp 10y agoNo, as I am yet to play with it. So far I only seen the presentations. But looking at Java 8 on this PC I would say: jvm.dll (8 MB) + main.exe (200 KB) + trimmed down JRE Also notice that from the presentations they have some experimental support for jlink plugins, which can further shrink down the size.