With Oracle remaining evil and Microsoft making waves in open source these days, I wonder how likely it is, for example, that a Big Data ecosystem like Hadoop/Spark/etc. could evolve around C# and .NET.
With Oracle remaining evil and Microsoft making waves in open source these days, I wonder how likely it is, for example, that a Big Data ecosystem like Hadoop/Spark/etc. could evolve around C# and .NET.
I really love the CLR, and I think it’s just as much “alien technology” as the JVM. I suspect the lack of love for it likely has more to do with the official versions being Windows-only than anything else. But I think it’s also just true that, while they both fill the same niche in a grand way (they’re both high-level VMs), their details are sufficiently different that a direct comparison doesn’t honestly make a ton of sense.
I think a comparison of them as products/platforms and the way the combination of technical and business decisions have influenced their trajectories is still interesting and instructive. Microsoft's very belated recognition that they won't be able to extend their OS dominance to all things server also means they've mostly squandered the technical advantages of the CLR. Oracle can catch up with the missing bits technologically (and they are doing just that) whereas it's by now really hard for the CLR to catch up in marketshare. Which is a pity.
It's retired now. I used it once, it worked pretty well.
(Note though that I have zero idea how GraalVM impacts any of this. It might completely negate all the things I flagged above.)
Python's most widely used CPython implementation uses a VM: https://leanpub.com/insidethepythonvirtualmachine/read
Ruby "compiles the abstract syntax tree into lower-level byte code. This byte code is then run by the Ruby virtual machine.": http://blog.honeybadger.io/how-ruby-interprets-and-runs-your...
Perl 6 runs on the Parrot VM: https://perl6.org/archive/architecture.html (and I believe Perl 5 had a different stack-based VM)
These days, more interpreted languages use VMs than not. One notable language runtime that does not use a virtual machine is the Chrome V8 JavaScript engine, which I believe compiles JavaScript directly into machine code and then executes it.
Most people run Rakudo Perl 6 on MoarVM, but it also runs on the JVM (with some caveats) and there is a JS based runtime that is being worked on.
I work with .NET and generally like it but .NET is still far, far away from the openness of Java. MS has open sourced a lot of stuff but it's still controlled by them. I also have my doubts for how long MS will sustain the move to open source. They have a long history of abandoning stuff like this after a few years and going back to business as usual.
They also had a long history under gates, then ballmer. It may be that under nadella, these sorts of moves are (or are becoming) the new 'business as usual'.
That's just PR. But real projects need sound technical motivations for making such a move.
The VM interpreter is generated from assembly code snippets that calls this class when something complex need to be done.
Hotspot is written in C++ and objects shared by Java and the VM can be seen either in Java or in C++ because they have a Java header and a C++ header.
Classloading is done lazily in Java so you can not preload classes until the first time you see it. If you see a non loaded class in the JITed code, you have to jump back into the interpreter and re-generate the assembly code later.
OSR stands for on stack replacement which means that while you are interpreting a loop, you decide to JIT its body.
Biased locking is a way to implement monitor/lock if those locks are used only by one thread, you biased the lock to that thread, which is slightly more efficient.
The stack contains stack frames of different kinds Java, C, adapters (assembly stubs between the 2 JITs and the interpreter which obviously doesn't use the same calling convention) but you have a common way to iterate on them.
All Hotspot GCs are generational so you have to hold every pointers (Java reference) into Handles (box known by the GC) because the GC may decide to move the objects while the C++ code hold them.
Obviously, all this mechanisms make sense but managing the complexity of all of them working together is insane.
I'd also throw in the Shenandoah GC from Red Hat. I don't remember the details anymore, but I remember thinking it was an amazing bit of code:
If tomorrow they really completely loose interest in Java and let everyone go, are the same Java companies that let Sun fall now going to rescue Java and keep developing OpenJDK?
MSFT is not making as big a wave as you'd think. A lot of the hype is MSFT PR machine running rampant.
I use Visual Studio/.Net on windows and only on windows because it's what many corporations use. But I use linux and bsd + vim/etc at home.
A lot of MSFT software may be going open source but they also bring with it "spying telemetry" and I suspect eventually ads. It surprises me how little outrage there is over MSFT spying as there is with facebook. Windows is literally a keylogger and scanner all in one. It's pretty much spyware.