Swiftpack.co - spevans/hypervisor-kit as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by spevans.
spevans/hypervisor-kit 0.0.2
Swift library wrapping Hypervisor.framework (macOS) and KVM (Linux) for x86_64
⭐️ 11
🕓 1 year ago
macOS
.package(url: "https://github.com/spevans/hypervisor-kit.git", from: "0.0.2")

HypervisorKit

A Swift library providing an interface for writing X86 hypervisors on macOS (Hypervisor.framework) and Linux (KVM).

Documentation is available here.

On macOS, Hypervisor.framework provides a very thin wrapper over the Intel VMX virtualisation instructions, allowing direct access to VMCS (Virtual machine control structures). Some functionality has to be implemented by the kernel, eg setting up EPT (Extended Page Tables) to map a process's memory into the virtual machine's address space.

Conversely, Linux KVM provides a more abstract interface as it is designed to work across multiple CPU architectures, eg x86_64, PPC etc and uses file descriptors and ioctl calls. KVM provides its own handling for vmexits and converts this to a smaller, simplified collection of KVMExits.

HypervisorKit aims to provide equivalent functionality on macOS to match KVM allowing cross platform virtual machines to be written for both macOS and Linux.

GitHub

link
Stars: 11
Last commit: 1 year ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics