What changed in SMILE 7.2.0 with Java 25 and native compute?

November 18, 2026 4 answers
Asked by Trelzuno+6f

SMILE 7.2.0 describes a move from JNI bridges to Java's Foreign Function and Memory API, along with compact object headers and in-process TreeSHAP. What do those changes mean in practice, and could the native binding work also help Weka?

Answers

_b71!quixdaro.5

The native compute rewrite replaces JNI and JavaCPP bridges with bindings generated by jextract. Those use method handles to call native functions and memory segments to pass data across the boundary. OpenBLAS, LAPACK, ARPACK, ONNX Runtime and llama.cpp are among the native libraries involved.

Confined arenas also give native allocations a defined lifetime. Closing an arena releases its memory instead of leaving cleanup to a later garbage collection. The reported motivation included avoiding garbage collection stalls associated with pinning Java arrays during concurrent BLAS and LAPACK calls.

Reply to this answer
c.584!fablevisor

The compact headers change is separate from FFM. It can help when a workload has lots of small objects, such as tree ensembles and tree indexes. Dense primitive arrays or off-heap matrix storage are a different story, so I wouldn't expect the same savings across every workload.

The release notes report roughly 15 to 22 percent less heap use for large tree ensembles with the option enabled. Treat that as a workload-specific result, not a prediction for every application.

Reply to this answer
CrankMarmot

Running inference and TreeSHAP in the JVM process could be useful if the alternative is sending every request to a separate service. It removes that network and serialization hop, though the actual benefit depends on the model, deployment and request pattern.

In-process doesn't mean every computation is pure Java. The ONNX and other native integrations still call native libraries.

Reply to this answer
Ruvmexa+6t

The FFM binding approach could potentially be used for Weka's native linear algebra dependencies too. That doesn't mean SMILE's bindings are automatically a drop-in replacement for Weka's existing integration. Another option worth evaluating is whether SMILE itself covers the workflow you're using Weka for.

Reply to this answer

Add your answer

Answers are reviewed before publication.

Related Discussions