How JDK 28 Lazy Constants and TornadoVM jitLLM 3.0 Transform Java Performance

🚀 Key Takeaways

  • JEP 547 advances toward JDK 28: Lazy constants enter their fourth preview round to deliver immutable, lazily initialized value holders without sacrificing critical JIT constant-folding optimizations.
  • JVM-native LLM inference breaks hardware barriers: Beehive Lab’s jitLLM 3.0 leverages TornadoVM to JIT-compile transformer kernels directly to GPUs, drastically cutting prefill latency and eliminating native memory copies.
  • Spring for Apache Pulsar moves to the ASF: Project governance officially migrates to the Apache Software Foundation as an integrated subproject to accelerate native messaging alignment.
  • Enterprise frameworks publish key milestone candidates: Coordinated preview releases across Spring AI, Spring Boot, and Hibernate ORM bring modern vector search, web routing improvements, and Jakarta Data support.
The modern Java ecosystem is undergoing a simultaneous evolution across low-level runtime semantics and compute-intensive enterprise runtimes.
As early-access builds of JDK 28 take shape, long-awaited language enhancements like computed constants are reaching architectural maturity, allowing developers to defer costly initializations while retaining strong immutability guarantees.

At the same time, the boundaries of JVM workload capabilities are shifting rapidly toward specialized hardware acceleration.
With groundbreaking advancements in TornadoVM-powered inference alongside structural project migrations across the open-source community, building low-latency, AI-augmented Java applications has never been more viable.


1. JEP 547 and Lazy Constants: Advancing Immutable Value Holders in JDK 28

Understanding the architecture of JDK 28 requires examining foundational JVM infrastructure upgrades alongside heterogeneous acceleration runtimes.
While execution engines like TornadoVM jitLLM 3.0 focus on compute-intensive hardware acceleration, JEP 547 addresses low-level data-holding latency by refining lazy constants directly within the OpenJDK platform.
Serving as a pivotal component of our exploration into "Understanding Lazy Constants and TornadoVM jitLLM 3.0 in JDK 28," this section examines how JEP 547 perfects immutable value holders through its fourth preview in JDK 28.

Core Mechanics and Evolution of Stable Values

JEP 547 proposes a fourth preview with no functional changes for JDK 28, solidifying the API design and internal runtime integration.
The mechanism addresses a classic tension in Java application design: the desire to delay resource-heavy initialization until an object is first accessed without forfeiting HotSpot's aggressive constant-folding optimizations.
Lazy constants decouple the creation of lazy constants from their initialization while preserving the safety guarantees and constant-folding performance benefits traditionally reserved for standard final fields.
Under the hood, the content of a lazy constant is stored in a non-final field annotated with the JDK-internal @Stable annotation.
This internal annotation informs the HotSpot Just-In-Time (JIT) compiler that once the field transitions from its default uninitialized state to a non-null payload, it can be treated as effectively constant across subsequent execution paths.
The architectural pathway leading to JEP 547 reflects steady stabilization across four successive Java platform releases.
Before being standardized under the title Lazy Constants in JDK 26, the underlying capability was formerly known as Stable Values and Computed Constants.
The following table outlines the lifecycle and JEP milestones that led to the fourth preview targeting JDK 28:
Java Release JEP Proposal Feature Status / Nomenclature Primary Focus
JDK 25 JEP 502 First Preview (Stable Values / Computed Constants) Initial API introduction and HotSpot @Stable alignment
JDK 26 JEP 526 Second Preview (Renamed to Lazy Constants) Refined naming conventions and API restructuring
JDK 27 JEP 531 Third Preview Ecosystem validation and runtime hardening
JDK 28 JEP 547 Fourth Preview Zero functional changes, verifying stability for targeted integration
As the feature entered the JDK 28 release pipeline, Mark Reinhold posted the formal review window deadline for integration, stating: "If no such objections are raised by 20:00 UTC on Wednesday, 18 November, or if they’re raised and then satisfactorily answered, then per the JEP 2.0 process proposal I’ll target this JEP to JDK 28."
This review window concluded alongside updates in early-access Build 24 of JDK 28, which shipped with upstream fixes over Build 23.

Lazy Collection Factories and Constant-Folding Constraints

In addition to individual scalar holders, the API provides specialized lazy collection factory methods.
These factory methods include List.ofLazy(...), Set.ofLazy(...), and corresponding Map factory methods.
These lazy structures enforce an explicit behavioral invariant: lazy constants strictly disallow null as a computed value.
This restriction ensures semantic alignment with standard unmodifiable collections (such as those returned by List.of) and JDK concurrency primitives like ScopedValue, preventing ambiguity between an uninitialized state and an intentional null outcome.
Despite these compilation and runtime benefits, specific structural constraints govern the deployment of lazy constants.
First, to be eligible for JIT constant folding, a lazy constant instance must itself be stored in a final field.
Second, constant folding for instance final fields is currently limited because core reflection historically allows instance final fields to be updated arbitrarily, except when hosted within records or hidden classes.
Finally, language design boundaries remain tightly scoped: it is not a goal of JEP 547 to add language syntax for lazy fields or alter the language-level semantics of final fields.
To compile and run programs with preview features enabled for lazy constants, developers invoke standard preview compilation and execution switches:
javac --release 26 --enable-preview Main.java
java --enable-preview Main
This command sequence compiles and executes Java source code while explicitly enabling the preview features of the Lazy Constants API, validating that the underlying runtime hooks behave predictably before commercial targeting.


2. TornadoVM jitLLM 3.0: JVM-Native Hardware Acceleration for LLM Inference

Connecting directly to the broader shifts in JDK 28 performance engineering, Beehive Lab has delivered jitLLM 3.0 as a JVM-native LLM inference and serving engine built directly on TornadoVM.
Beehive Lab describes jitLLM with a clear value proposition: "Think vLLM — but pure Java, and it runs on any GPU."

Bytecode-to-Kernel JIT Compilation and Memory Architecture

TornadoVM handles execution by JIT-compiling transformer kernels from standard Java bytecode into CUDA, OpenCL, or Apple Metal at runtime, bypassing the need for hand-written JNI glue code.
This direct execution model reshapes memory pipeline efficiency.
The engine completely eliminates intermediate memory copies from mapped GGUF model files into Apple Metal hardware buffers, streaming weights straight into execution-ready hardware memory.
Furthermore, jitLLM 3.0 implements on-device greedy sampling, which reduces device-to-host traffic by approximately 500 times per token by evaluating logits on the GPU before sending results back to host memory.
When compiled ahead-of-time with GraalVM Native Image, jitLLM 3.0 achieves 1.43 times faster startup times, eliminating standard JVM warm-up penalties during deployments.

Throughput Benchmarks and Multi-GPU Layer Splitting

In raw execution performance, jitLLM 3.0 delivers an up to 9.3 times faster prefill phase alongside massive prompt processing improvements across both desktop-class and enterprise accelerators.
For batched operations, batched decode provides up to 41 times aggregate throughput for Llama and Qwen3 FP16 models running on CUDA.
For larger deployments, the engine supports model splitting across multiple GPUs by layer ranges using NCCL or host transport mechanisms to distribute computational overhead evenly.
Model Architecture Precision Hardware Platform Prompt Processing / Throughput Acceleration / Configuration Notes
Llama-3.2-1B Q8_0 NVIDIA A100 Increases from 4.9k to 29k tok/s TornadoVM CUDA execution
Llama-3.2-1B F16 Apple M4 Pro Increases from 40 to 2372 tok/s Zero-copy Metal buffer mapping
Qwen3-0.6B F16 Apple M4 Pro 4171 tok/s Apple Metal native execution
Qwen3-0.6B F16 NVIDIA A100 54k tok/s cuDNN attention backend
Llama / Qwen3 FP16 CUDA (Batched) Up to 41x aggregate throughput Batched decode acceleration

Hardware Compatibility and Ecosystem Integration

To launch the jitLLM serving engine or run GPU inference from the CLI, developers utilize the built-in CLI entry points:
jitllm serve
jitllm --gpu
Executing jitllm serve starts an OpenAI-compatible HTTP server providing /v1/chat/completions and /v1/completions endpoints, while the --gpu parameter runs inference using TornadoVM's auto-detected GPU backend.
This drop-in server interface is accompanied by official provider integrations for both LangChain4j and Quarkus inference engines, allowing direct inclusion in enterprise Java stacks.
Deployments must account for specific hardware constraints.
NVIDIA Blackwell GPUs (RTX 50 series, B200) require cuBLAS 12.8 or newer; running older versions forces generic kernels that execute 2 to 3 times slower.
On Apple silicon, native Metal acceleration requires an M4-class GPU and the MLX 0.32.3 kernel library.


3. Spring for Apache Pulsar: Navigating the Governance Transition to the ASF

As modern enterprise architectures adapt to foundational runtime shifts such as lazy constants and accelerated execution via TornadoVM jitLLM 3.0 in JDK 28, the higher-level messaging and event-driven frameworks supporting these workloads are undergoing structural governance transformations.
A significant evolution within the cloud-native messaging tier is the official relocation of the Spring for Apache Pulsar project into the Apache Software Foundation (ASF).
This shift redefines how high-throughput messaging capabilities are integrated, maintained, and delivered to Java enterprise applications.

Subproject Migration and Release Lifecycle Milestones

The Spring for Apache Pulsar project is officially transitioning to the Apache Software Foundation as a formal subproject hosted under the Apache Pulsar umbrella.
Following this governance transfer, the project will be officially named Apache Pulsar support for Spring.
Under this new structure, all ongoing maintenance, bug fixes, feature enhancements, and subsequent release cycles will be directed by the Apache Pulsar project community rather than tracking active Spring release trains.

This handover establishes a strict release lifecycle boundary for existing artifacts.
Spring for Apache Pulsar version 2.0.8, released in October 2026, marks the final release under the Spring project umbrella.
Direct maintenance of the Spring Boot starter for Spring Pulsar under the Spring engineering team ceases following version 2.0.8 alongside Spring Boot 4.2.0.
The Spring team highlighted the strategic benefits of this relocation, stating: "Bringing this integration directly into the Apache Pulsar project allows the community to streamline development, accelerate feature support, and ensure long-term alignment with the evolution of Apache Pulsar."
Component / Milestone Version / Scope Governance Authority Lifecycle Status
Spring for Apache Pulsar Version 2.0.8 Spring Project Umbrella Final release under Spring governance (Released October 2026)
Spring Boot Starter Integration Spring Boot 4.2.0 (with Pulsar 2.0.8) Spring Team Maintenance ceases under Spring release train
Apache Pulsar support for Spring Post-2.0.8 Releases Apache Software Foundation (ASF) Active development and ongoing feature releases
Spring Cloud Stream Binder Version 5.1.0 Spring Cloud Stream Incorporates the Apache Pulsar binder in upcoming release

Dependency Transition and Spring Cloud Stream Alignment

To continue receiving security patches, feature developments, and maintenance updates, developers must update their build definitions and project dependencies.
This migration requires developers to transition their existing Maven and Gradle dependency coordinates and adjust application package imports to point directly to the new Apache Pulsar subproject coordinates.
Failing to adopt the relocated coordinates will leave applications pinned to the final 2.0.8 release baseline without downstream fixes.

Simultaneously, the broader Spring ecosystem is aligning its streaming abstractions with this restructured framework.
Spring Cloud Stream will formally include the Apache Pulsar binder in its upcoming version 5.1.0 release.
This ecosystem alignment ensures that teams building messaging pipelines retain native streaming integration options while downstream engineering activities consolidate under the ASF's direct domain expertise.


4. Java Ecosystem Milestones: Enterprise Frameworks and Cloud-Native Tooling Updates

While runtime innovations like Lazy Constants and TornadoVM jitLLM 3.0 redefine low-level performance and hardware acceleration in JDK 28, the enterprise Java ecosystem continues to evolve in tandem across application frameworks, persistence specifications, and cloud-native build infrastructure.
Tracking these milestone releases demonstrates how production stacks adapt to modern distributed workloads, reactive pipelines, and artificial intelligence integration alongside platform-level enhancements.

Spring AI and Spring Boot Cloud-Native Capabilities

The Spring ecosystem delivered significant enhancements across AI integration and cloud routing in its recent milestone iterations.
Spring AI 2.1.0-RC2 introduced the DecisionModel interface, designed specifically for outcome probability computation.
Complementing this capability, Spring AI 2.1.0-RC2 added a dedicated float-array similaritySearch method to VectorStoreRetriever, streamlining direct mathematical vector operations against semantic indexes.
In the application runtime domain, Spring Boot 4.2.0-RC2 expanded its network proxy capabilities by adding X-Forwarded-Prefix HTTP header support when running on Reactor Netty.
Additionally, Spring Boot 4.2.0-RC2 improved multi-node data store operations by ensuring that Redis database assignments reliably apply across complex master-replica configurations.

Jakarta Persistence Advancements in Hibernate, GlassFish, and TomEE

Data access frameworks and Jakarta EE application runtimes have advanced their alignment with modern specifications, led by progress around Jakarta Persistence 4.0.0-M7 and Jakarta Data 1.1.0-M4.
Hibernate ORM 8.0.0-RC1 arrived as an implementation of both Jakarta Persistence 4.0.0-M7 and Jakarta Data 1.1.0-M4, introducing the coordination of graph-based flushing for pending entity and collection mutations.
In the non-blocking persistence space, Hibernate Reactive 5.1.0-RC1 and 5.0.0-RC1 aligned collection table locking via the EXTENDED pessimistic lock scope with Hibernate ORM, while introducing new observability hooks directly into VertxFactory.
On the application server front, GlassFish 9.0.0-M4 implemented Jakarta Persistence 4.0.0-M7 backed by EclipseLink 6.0.0-M1, updated its Eclipse JNoSQL integration to versions 1.2.0-M2 and 2.0.0-M1, and decoupled administrative assets by moving the Sun Theme module into its own core module alongside the Admin Console.
Concurrently, Apache TomEE 11.0.0-M2 delivered extensive security hardening by resolving 38 CVEs and implementing Jakarta Authorization 3.0.
Within this distribution, Apache TomEE Plume modernized its internal persistence architecture by replacing its legacy monolithic EclipseLink uber-JAR with modular JPA artifacts.
Project / Artifact Release Version Key Specification / Structural Milestone
Hibernate ORM 8.0.0-RC1 Implements Jakarta Persistence 4.0.0-M7 and Jakarta Data 1.1.0-M4; adds graph-based mutation flushing.
Hibernate Reactive 5.1.0-RC1 / 5.0.0-RC1 Aligns EXTENDED pessimistic lock scope collection locking with ORM; adds VertxFactory observability hooks.
GlassFish 9.0.0-M4 Implements Jakarta Persistence 4.0.0-M7 with EclipseLink 6.0.0-M1; updates Eclipse JNoSQL to 1.2.0-M2 and 2.0.0-M1.
Apache TomEE 11.0.0-M2 Implements Jakarta Authorization 3.0; resolves 38 CVEs; replaces Plume EclipseLink uber-JAR with modular JPA artifacts.

Infrastructure and Build Automation Tooling Updates

Cloud-native infrastructure and continuous delivery pipelines also registered targeted stability and workflow improvements.
Quarkus introduced the Quarkus Resiliency Testing utility, leveraging the standard @QuarkusTest annotation harness to validate application behavior under failure conditions.
JobRunr 9.0.4 hardened its distributed background processing build chain by migrating builds to hardened Docker images designed for optimized layer caching and enhanced environment security.
Seed4J addressed developer velocity and storage footprint in versions 2.3.0 and 2.4.0 by restricting Playwright browser installations exclusively to projects containing component tests, alongside deploying a shared global Maven build cache.
Finally, release automation tooling saw breaking CLI refinements in JReleaser 2.0.0-SNAPSHOT, which removed the -a and -d short command-line option flags to eliminate syntax parity discrepancies with the full --changelog and --announce commands.

Generative AI may have assisted with research or drafting for this article. Topic selection, fact-checking, final wording, and publication remain the responsibility of DragonStone74. AI use disclosure