Join the discussion

Write your take first — we'll ask for email only when you're ready to publish.

  • Hacker News
  • A bit fuzzy and dramatic; luckily the original documents are quite readable:

    top-level page: https://openjdk.org/projects/jdk/28/spec/

    JEP status: https://bugs.openjdk.org/secure/Dashboard.jspa?selectPageId=...

    I'd really like to see someone trace related developments in C#, Swift, Java, and Rust, since they all have been racing to catch up to hardware, and I believe they are cross-pollinating.

    (My concern is how all this will affect the FFI memory shares.)

  • I know its a faux pas in the Java world to acknowledge the existence of .NET, but how does this differ from .NET structs?

    Value types, generic specialization, boxing - a quick skim makes it looks like they picked the same choices.

  • > But careful: == looks at internal state, which isn’t always what the object represents, so for “is this the same data” comparisons keep using equals.

    So == for value classes will basically be like memcmp(). That is a bit unfortunate, as it breaks encapsulation, exposing implementation details. Client code can use this to do case distinctions based on how a given value is internally represented. In a way, it’s worse than identity comparison, because identity comparison at least doesn’t expose internal state.

  • You could probably a whole tech thriller on the evolution on Value Types in Java.

    I’ve been reading the mailing lists and watched all videos on the topic and it is truly inspiring how much they managed to consolidate the design to something that always looked like java.

    But while also going far deeper in granularity and understanding what it even means to be a value type and what optimizations can be done where

  • A lot of the comments on here are a bit unfair on what is great work being done and even more awesome work (JEPs) in the pipeline for the future.

    If Java was a child, imagine it being brought up by loving parents for the first few years (Sun) then it was thrown in a garage with some other children and neglected by its evil guardian (Oracle)

    Neglected and unloved till JDK 8, its basically been playing catch up.

    So when people say "oh so its now got structs or value types of X", yes it has but that's because it has been stunted in its development due to big bureaucratic and hostile corporate processes, but its free now and is getting love through the OpenJDK family.

    I will continue to enjoy writing once and deploying anywhere!

  • After reading a lot of comments in here, there is one thing that always repeats itself in Java/JVM-related comment sections on HN. There are a surprising number of people who have an idea of what the JVM or Java used to be and have very little idea of what it is today. It is a very fit predator in 2026. Does it have its warts? Yes, but the substrate is extremely good.
  • > But the difference in memory is fundamental. The JVM can now store the values themselves in the array, laid out densely one after another: 8 bytes per point (plus a possible null flag), in a contiguous block. No headers per element. No pointers. No jumping around the heap.

    How much was this article proof-read? Didn't they just get finished talking about how heap flattening won't work for objects with > 64-bit representations? Their `Point` is at least 65 bits (two 32-bit ints plus the null flag). The "plus a possible null flag" and oddly short following statements seem to suggest this was some AI that got sidetracked by trying to make emphatic statements... oh and also the "[IMAGE: the same Point[] array in two variants..." block halfway down the page is unfortunate.

  • I appreciate the hard work that went into the things that did make it into Valhalla eventually, but:

    > The model was powerful, but also mentally heavy

    No it isn't! it is this interpretation that kills off the null-safety debate entirely. Saying you have a variable that cannot be null is not a mentally taxing distinction, especially since everything is labelled thoroughly.

    > The team, faithful to the lesson “simplify the model for the user, even at the cost of the performance ceiling,” ultimately dismantled this dualism.

    but it would have simplified it for the user.

    The whole attitude and process around this and the other topics gives me very little faith that Java can be steered in a sensible direction here. The type system of a programming language is supposed to give convenient guarantees to the developer on a CPU that can only do numbers. There is no reason to reduce the optional(!) safety guarantees you can offer with the excuse of "too mentally taxing".

    Hell, they even get there half way by recognising:

    > the language model and the JVM model don’t have to overlap one hundred percent

    by rf15

Explore Birbla archives