Live data from Hacker News

Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

graalvm.org

101–110 of 141 posts

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#101

Earlier quoted context omitted.

It may not only be benevolence though. The JVM and Graal are not the only game in town anymore. Webassembly is growing in various areas, clienside, edge, backend. WASM fills much of the same needs as Graal, and then some since it’s embedded in every major browser. This move is good for Graal, as it will help it compete, but there’s still a big question in my mind at least about if Graal is going to be able to compete…

WASM isn't really a replacement for JVM bytecode. It's not like you can take a random JAR and convert it to WASM. Last I checked, WASM doesn't even support GCd languages at all, and at any rate the whole insight that makes GraalVM unique and a big deal is that universal bytecodes are a poor choice for making fast polyglot VMs. The JVM world was doing that long before WASM was even a twinkle in Google's eye, with invo…

> WASM doesn't even support GCd languages at all

Well, some GC'd languages support compilation to WASM, for example, you can compile go to WASM. The issue here is that for GC'd languages you have to bring your own runtime with GC in every module, so this doesn't really work.

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#102
post #55

Earlier quoted context omitted.

It may not only be benevolence though. The JVM and Graal are not the only game in town anymore. Webassembly is growing in various areas, clienside, edge, backend. WASM fills much of the same needs as Graal, and then some since it’s embedded in every major browser. This move is good for Graal, as it will help it compete, but there’s still a big question in my mind at least about if Graal is going to be able to compete…

Is there a current WASM implementation that can out perform HotSpot? Will WASM ever outperform it? I highly doubt it.

GraalVM? :-)

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#103
post #32

Earlier quoted context omitted.

This is what it is. GraalVM is implemented in Java, there is a Truffle framework that compiles Java, Ruby, JS, Python to Java Truffle, which then runs on GraalVM JIT compiler.

Wait, GraalVM is implemented in Java ? Does that mean to run it you need another JVM to run it on top of? That sounds stupid... Maybe you need another VM just to run it on once, so it can translate itself to native code on the target?

Lots of languages and run times are self hosting today. There are several Java VMs out there. This is but one of them. Its been demonstrated that it's not that hard to create an operational Java VM from scratch. A straightforward interpreter can do the job. The VM doesn't change the source language.

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#104
post #67

Earlier quoted context omitted.

Java often is as fast as cpp, sometimes faster. JIT gives it a huge advantage and c2 is pretty much state of the art these days.

No. Compare SweetHome 3D to any similar tool written in C++.

There are 3 separate statements you could make.

SweetHome 3D IS slower than competitive projects written in C++.

C++ tools tend to be faster than comparative Java tools because of fast startup time, no GC, and being the default choice for performance sensitive projects for decades.

C++ is definitively faster because of inherent advantages.

You appear to be jumping to the third based on the first which appears erroneous in argument even if you turned out to be correct. In actuality it appears that for most things in the same ballpark language choice isn't necessarily the only or even the most important factor. This is even more true for things where startup time is an inconsequential factor, with better GC that doesn't result in lengthy pauses, and where development time is a substantial limiting factor wherein being quicker to work with may result in more time available to improve other design choices yielding as good or better results.

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#105

Earlier quoted context omitted.

WASM isn't really a replacement for JVM bytecode. It's not like you can take a random JAR and convert it to WASM. Last I checked, WASM doesn't even support GCd languages at all, and at any rate the whole insight that makes GraalVM unique and a big deal is that universal bytecodes are a poor choice for making fast polyglot VMs. The JVM world was doing that long before WASM was even a twinkle in Google's eye, with invo…

python support seems fairly experimental right now: https://www.graalvm.org/22.3/reference-manual/python/ or is that something different?

It's "experimental" in the sense that it's incomplete, but the core tech is mature and works fine. Full support means supporting all the third party modules along with interpreter extensions, every part of the standard library etc.

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#106
post #18

I don't say nice things about Oracle very often, but they deserve some praise here. Graal is a very, very ambitious project, and Oracle has been funding it for years. It's still rough around the edges, but it promises to enable new programming languages to run on a high-performance JVM, compiled to native code. Write-once, run anywhere, at native speed. And now they're donating it. It's very decent of them.

Maybe a newb question but may I ask for an explanation why someone would want Python to run on the JVM and how they'd get started? Is it adaptable to a Poetry-led workflow?

> why someone would want Python to run on the JVM

* to run faster

* to get a better JIT compiler, better GC, sandboxing, etc

* to run using code from other JVM languages in the same process

* to get the JVM's monitoring tools

* to embed into a Java application

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#107
post #18

I don't say nice things about Oracle very often, but they deserve some praise here. Graal is a very, very ambitious project, and Oracle has been funding it for years. It's still rough around the edges, but it promises to enable new programming languages to run on a high-performance JVM, compiled to native code. Write-once, run anywhere, at native speed. And now they're donating it. It's very decent of them.

Maybe a newb question but may I ask for an explanation why someone would want Python to run on the JVM and how they'd get started? Is it adaptable to a Poetry-led workflow?

Here are some nice examples: https://www.graalvm.org/22.2/reference-manual/python/Interop...

This may be more readable: https://github.com/oracle/graalpython/blob/master/docs/user/...

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#108
post #47

Earlier quoted context omitted.

I know absolutely nothing about Oracle, GraalVM, OpenJDK, or Java development in general. I haven't used Java since a CS intro class during my undergrad like 10 years ago. Despite this, I've internally adopted the general consensus that Oracle is a terrible, greedy company. Can someone play devil's advocate to explain how this news may actually favor this negative view of Oracle? The sentiment in this thread is prais…

There's an epic rant on youtube from one of the old Sun guys that gets linked occasionally. I can't remember all of it, but basically it goes that Larry Ellison/Oracle is just as simple as a lawnmower - if you stick your hand in it; it'll shred it without emotion because it's just an unthinking machine that cuts whatever you put into in the same way that Oracle is a machine to make money. I've been at this long enoug…

It seems irrational for anyone to feel unexpectedly angry at a lawnmower for shredding their hand though -- you should have known it was a lawnmower, that's not a recent change, and it never claimed to be anything but a lawnmower. You should just be the normal level of angry that lawnmowers are dangerous.

The parent apologist was extremely precise in how they described Oracle. Oracle isn't in the "Be warm and fuzzy to developers" business: they're in the "Provide mission critical software to large enterprises" business. Logic for servicing the latter well makes things look screwy or sinister to people used to the former.

Which isn't to say the Oracle salespeople aren't scummy. But most salespeople are scummy. That's what happens when you incentivize closing sales, which is how almost all sales orgs are set up. So audit model + scummy salespeople = bad experiences. But to parent's point: what's a better model for their customer persona?

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#109
post #5
post #3

Earlier quoted context omitted.

It's a good point, after so long why the JVM is not written in Java actually? For example the Go runtime and I think C# as well are written in their respective language. https://github.com/golang/go/tree/master/src/runtime https://github.com/dotnet/runtime

Maybe it's my ignorance of the Java ecosystem or a lack of imagination but how could a language that requires a heavy runtime be written in itself? Wouldn't you need a runtime for the runtime, and then a runtime for the runtime for the runtime and then...? I can't quite imagine how you'd bootstrap something like that.

By using an existing implementation, and having intrisics.

There are a couple of Java implementations written in Java, Jikes RVM being one of the first ones, almost 15 years ago.

Re: Oracle Contributing GraalVM Community Edition Java Code to OpenJDK

#110
post #3
post #2

Maybe we will soon see the Java Virtual Machine implemented wholly in (a subset of) Java...

It's a good point, after so long why the JVM is not written in Java actually? For example the Go runtime and I think C# as well are written in their respective language. https://github.com/golang/go/tree/master/src/runtime https://github.com/dotnet/runtime

There are a couple of Java implementations written in Java, Jikes RVM being one of the first ones, almost 15 years ago.

GraalVM is the evolution of MaximeVM, originally developed at SunLabs, also about 15 years ago.

Post reply on HN