Implementing a Simple JVM in Rust by Ben Evans

preview_player
Показать описание
The JVM is a truly remarkable piece of software, but it is still just a computer program, not magic! In this talk, I will explain how we might start to implement a JVM from scratch, using the Rust programming language. Fundamental concepts such as the bytecode interpreter, classfile parsing and memory management will be explained using an open-source implementation as reference.

We will build up a working interpreter capable of executing simple methods (initially represented as byte arrays).

From there, we add features and build towards a more complete implementation that can actually execute simple Java classes. The talk is largely live coding in the IDE, where I will work with an implementation of the JVM written in Rust.

The implementation is designed to be easy to understand even for developers who are new to language implementation.

No real Rust experience is required - as I will provide a primer on the language in the first half of the talk.

Ben Evans is an author, speaker, architect and educator. He is currently Principal Engineer and JVM Architect at New Relic. Previously, he was a co-founder at jClarity, a performance tooling company and before that was Chief Architect for Listed Derivatives at Deutsche Bank. Ben served for 6 years on the Java Community Process Executive Committee, helping define standards for the Java ecosystem. He is a Java Champion, 3-time JavaOne Rockstar Speaker and the Java / JVM Track Lead at InfoQ.

Ben is author of “The Well-Grounded Java Developer”, “Java: The Legend”, "Optimizing Java" and the new editions of “Java in a Nutshell”. Ben is a regular speaker and educator on topics such as the Java platform, systems architecture, security, performance and concurrency at conferences all over the world.
Рекомендации по теме
Комментарии
Автор

"the rust compiler is really really quick"
That is the first time I've ever heard this sentence.
But I agree, compared to java, rust compilation time is a breath of fresh Air

Iogoslavia
Автор

I'm really happy to see the Java community start to take notice of Rust. For your interpreter look at the crossbeam crate. It has a bunch of useful stuff for concurrency, like atomic types and shareds. It also has an epoch based garbage collector that is "relatively" simple to integrate with.

Codeaholic
Автор

Amazingly this is still being actively developed, last commit was 3 days ago.

MrHatoi
Автор

I’m a student I’m currently at my first rust project which is also a VM and I intend to impl a GC for it. So hearing him say GC is too had kinda makes me nervous lol

cat-.-
Автор

>rust talk
>opens with “Ben Evans (he/him)”
The jokes write themselves.

robertkiestov
Автор

Half the time is spent on "who all know what" :). Anyway decent talk

thajafsal