7 ms·
Notice how I separately addressed JVM and Java. Java is already losing market share to JVM competitor languages. JVM is in a stronger position than Java, but
by dtech 7y ago
Notice how I separately addressed JVM and Java.
Java is already losing market share to JVM competitor languages.
JVM is in a stronger position than Java, but imagine a world were 15-10 years ago native compilation for JVM bytecode became available instead of 1 year ago. LLVM wouldn't have stood a chance.
Kotlin and Scala (I'm not too familiar with Clojure and others) are hedging their bets and making JS/Webassembly and LLVM versions.
- pjmlp 7y agoJVM native compilation exists since 2000 for anyone willing to pay for it.
- aphexairlines 7y agoDo you mean with Excelsior JET? I tried to compile an application totaling 157MB in jars to native with it just now. After compiling for 2 hours it was still only 15% done. I had aggressive optimizations disabled.
- pjmlp 7y agoExcelsior JET is only one among many. As for your problem, it looks very strange to me, only similar to compiling C and C++ on underpowered hardware.
- ptx 7y agoWhich are the other ones? I know of GCJ, which is dead, and Graal, which from what I hear takes hours to compile small programs.
- pjmlp 7y agoMost commercial JVMs for embedded development. For example, PTC, Aicas, Aonix (now also owned by PTC), IBM RealTime WebSphere, some variants of J9, Android since version 5 (although it isn't technically a JVM), RobotVM, Codename ONE, GluonVM, IBM i JVM (uses OS/400 TIMI), JRockit.
- fnordsensei 7y agoI know for a fact that in the case of Clojure (and I assume the reasoning is similar for Kotlin and Scala) that targeting other ecosystems has nothing to do with "hedging", and everything to do with reaching other platforms and mediums.
- repolfx 7y agoLLVM would have been created even if free/open source, SubstrateVM style tech existed back then because LLVM was designed as a competitor to GCC for compiling C and C++. The JVM can run C/C++ code these days 'natively' (by JIT compiling LLVM bitcode using Sulong) but that's not what it was created to do. Also bear in mind LLVM is not really a JVM competitor despite the name. LLVM is a toolkit for building compilers, primarily, C/C++ compilers. Other languages that targeted it have had to do a lot of work to change LLVM for that language. It's not actually a "VM" in the JVM or V8 sense, for instance, it doesn't provide a garbage collector and LLVM bitcode is neither platform neutral nor a stable format.
- dtech 7y ago> Also bear in mind LLVM is not really a JVM competitor despite the name. LLVM is a toolkit for building compilers It started out as a (lower-level than JVM) VM and evolved into what it is now, mainly because of Apple's requirements and funding.
- coldtea 7y ago>Java is already losing market share to JVM competitor languages. Really, any examples? And not Go and Rust (down 30+ places in the TIOBE index compared to Java, and as insignificant as to not even exist in the global job market).
- deleted 7y ago[deleted]