This blog post is an intro series on our future contributions around the Xen Project, related to bring replacement programs in Rust, at various levels

Bringing Rust to the Xen Project

submited by
Style Pass
2023-03-17 15:00:02

This blog post is an intro series on our future contributions around the Xen Project, related to bring replacement programs in Rust, at various levels in the stack.

The whole platform that makes up XCP-ng contains a lot of various programs: Xen (the hypervisor), the XAPI (the API/toolstack), SMAPI (storage stack) among many other things, like guest tools and so on.

This platform is a mix of various languages like C, Python, OCaml and even Go. Some components are somehow old and not easily maintainable. We wanted to use that opportunity to rethink some of them, and use that opportunity to bring Rust to the table.

There's many reasons for that. You could argue there's already 4 languages used inside XCP-ng, so why add another? Luckily, Go is only used for one component we might entirely replace, there it won't raise the overall number of languages used. Good, but why then?

Rust will be bring both performance and memory safety, which is -in my opinion- truly relevant in a virtualization platform like XCP-ng. The fact there's no garbage collector is also very attractive to us. Then, the borrow checker is also an extra feature that might help us to reduce potential bugs, which is another plus. But there's more than just technical reasons!

Leave a Comment