~/talk

Java Enable Preview: Foreign Function and Memory Interface

Talkat Great International Developer Summit 2025 · 2025-04-22..04-25· [java]
links:none on file
slides:none on file

Preview of Java’s Foreign Function & Memory Interface shows concrete steps: allocate arenas and memory segments, create a native linker, do a symbol lookup, build a function descriptor and obtain a downcall MethodHandle, then invoke C (examples compile to .dylib/.so/.dll). JDK 22 / Project Panama ships the API, Jextract generates Java bindings from headers, restricted native access requires an explicit runtime flag, and demos include C structs, pointer reinterpretation and calling a Rust library.

AI-written summary · about

  1. 0:00Introduction to FFM API
  2. 1:32What is Foreign Function Memory API
  3. 13:54Understanding Arenas
  4. 16:46Linkers and Down Calls
  5. 21:19First Demo: Calling C Functions
  6. 27:00Memory Segments and Allocation
  7. 30:11Working with Structs
  8. 33:46Handling Pointers
  9. 38:04Receiving Pointers from C
  10. 43:51Callbacks and Up Calls
  11. 49:31Restricted Methods
  12. 51:17JExtract Tool Overview
  13. 56:35Demo with Rust Library
  14. 1:00:13Q&A and Conclusion
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.