SlideShare a Scribd company logo
1 of 30
Static Partitioning
Virtualization on RISC-V
José Martins and Sandro Pinto
RISC-V Summit @ Virtual
December 8th, 2020
Agenda
Introduction
Motivation and Background
01
RISC-V Virtualization
RISC-V virtualization in a nutshell
02
RISC-V H-Extension
Implementation & enhancements
03
Evaluation
Tests, experiments, and results
04
Conclusion
Final thoughts and Takeaways
05
Introduction
Motivation and Background
Mixed-Criticality
4
ESRGv3 RISC-V Summit 20
• High Complexity
• Multiple Subsystems
• Heterogeneous Software Stacks (RTOS, GPOS)
• Different Criticality Levels
• Size, Weight, Power and Cost (SWaP-C)
Automotive
Industrial
Automation
Embedded Virtualization
5
ESRGv3
ESRGv3 RISC-V Summit 20
Consolidation
Size
Weight
Power
Cost
Low Engineering Cost
Full-Virtualization allows
direct porting of guest OSs
Fault Containment
Sandboxed Enviroments
Performance
Low Virtualization Overhead
Close to Native Performance
Security
Small TCB
Side-channel
TEE support
Open Design
Real-time
Low latencies
Determinism/Predictability
Freedom-from-interference
Traditional Hypervisors
6
ESRGv3
▪ Not designed for embedded/MCS:
▪ Although retrofitted with success
▪ High-overhead IO:
▪ Emulated
▪ Para-virtualization/Backend-drivers
▪ Large Code Base :
▪ Hosted hypervisor
▪ Privileged VMs run large monolithic OSs
(typically Linux) part of TCB.
ESRGv3 RISC-V Summit 20
Static Partitioning Virtualization
7
ESRGv3
Jailhouse
 Static Partitioning:
 Thin configuration/partition layer
 1:1 vCPU-to-pCPU mapping
 Static memory assignment
 Device Pass-through
 Hardware interrupts
 Jailhouse:
 Needs “root cell” to boot and manage VMs
 Large boot time
 Xen Dom0-less*:
 DomUs may boot w/o Dom0
 Direct Device assignment
Dom0-less
ESRGv3 RISC-V Summit 20
* https://www.youtube.com/watch?v=OrtV6gyHW74
Bao Overview
8
ESRGv3
01
02 03
 Type-1 / Bare-metal
 Static Partitioning:
 1:1 vCPU-to-pCPU mapping
 Static memory assignment
 Device Pass-through
 Hardware-assisted:
 2nd-stage translation
 Interrupt virtualization support
 IOMMU
 Dependencies:
 No external libraries / privileged VMs
 Small TCB (~7K SLoC)
 Real-time & Security:
 Predictability / Freedom-from-interference
 Side-channels / TEE support
ESRGv3 RISC-V Summit 20
José Martins, Adriano Tavares, Marco Solieri, Marko Bertogna, and Sandro Pinto. "Bao: A Lightweight
Static Partitioning Hypervisor for Modern Multi-Core Embedded Systems". In NG-RES 2020
https://drops.dagstuhl.de/opus/volltexte/2020/11779/
Bao Hypervisor Support
9
ESRGv3
01
03
 Architectures:
 Armv8-A
 RISC-V (v0.6.1 Hyp Spec.)
 Platforms:
 Zynq US+ (ZCUx and Ultra96)
 HiSilicon96 (Hikey96)
 NXP i.MX8
 Nvidia Tegra TX2
 QEMU
 Rocket @ ZCU
 Firmware:
 Arm Trusted Firmware (PSCI) on Arm
 Supervisor Binary Interface (SBI) on RISC-V
 U-boot
 Guests:
 Bare-metal
 Linux / Android
 RTOSs (FreeRTOS, Erika)
ESRGv3 RISC-V Summit 20
RISC-V Virtualization
RISC-V virtualization in a nutshell
Hypervisor Extension
11
ESRGv3
 Designed for type-1 and type-2 hypervisors
 Additional execution modes
 HS-mode (hypervisor-extended supervisor)
 VS-mode & VU-mode
 Additional CSR registers:
 HS-mode CSRs for hypervisor capabilities (e.g., hstatus)
 HS-mode CSRs for accessing Guest/VM state (e.g., vsstatus)
 Two-Stage MMU:
 Stage 1: VS-mode page table (GVA -> GPA)
 Stage 2: HS-mode guest page table (GPA -> HPA)
ESRGv3 RISC-V Summit 20
https://github.com/riscv/riscv-isa-manual/releases/latest
Hypervisor Extension
12
ESRGv3
ESRGv3 RISC-V Summit 20
Hypervisor
Firmware (SBI)
Decreasing
Privilege level
M
Guest OS
Guest User Space Host User Space
Virtualised Environment Non-virtualised Environment
HS
VS
Adapted from: Alistair Francis (WD), “Developing the RISC-V Hypervisor Extensions in QEMU”, Embedded Linux Conference Europe, 2019
VU
M
HS
U
Spec Status
13
ESRGv3
ESRGv3 RISC-V Summit 20
 Currently version 0.6.1
 Feedback from open source projects
 Contributions from organizations and individuals
 H-Extension spec close to freeze state
 Hypervisor “group” (join RISC-V Hypervisor sync-up calls!)
 Function completeness (KVM & Xvisor)
 RTL implementations (we have contributed with one )
 KVM and Xvisor running on FPGA implementation (we have ran Xvisor on an FPGA )
 Open source projects support:
 QEMU (v0.6.1)
 KVM and Xvisor (v0.6.1)
RISC-V Hypervisors
14
ESRGv3
 KVM:
 Type-2 hypervisor, Linux-based architecture, open-source
 Enterprise virtualization setups (datacenters and private clouds)
 https://github.com/kvm-riscv/linux
 Xvisor:
 Type-1 hypervisor, monolithic architecture, open-source
 Embedded systems with soft real-time requirements
 https://github.com/avpatel/xvisor-next
 Bao:
 Type-1 hypervisor, static partitioning architecture, open-source
 Mixed-criticality systems with strong real-time and security requirements
 https://github.com/bao-project/bao-hypervisor
ESRGv3 RISC-V Summit 20
RISC-V H-Extension
Implementation & enhancements
Spec Checklist
16
ESRGv3
01
02 03
 H-Extension, Version 0.6.1
 RV64 and sv39 only
 Implemented:
 h- and vs- csrs and respective functionality
 m- registers extended accordingly
 hypervisor load/store instructions
 new virtual instruction exception
 hfence instructions (limited, flushes complete TLB)
 guest external interrupts (w/ PLIC virtualization extension)
 Not Implemented:
 ASID/VMID support
 Transformed Instruction or Pseudoinstruction for htinst/mtinst
ESRGv3 RISC-V Summit 20
H-Extension Implementation
17
ESRGv3
01
02 03
 Available at: https://github.com/josecm/rocket-chip/tree/hyp
 Synced with chipyard’s master branch commit of rocket-chip (@1872f5d, 6
months ago)
 ~1100 sLOC modifications to rocket-chip. Mainly on:
 CSR
 PTW
 TLB
ESRGv3 RISC-V Summit 20
H-Extension Implementation
18
ESRGv3
01
02 03
 Next Steps:
 Refactoring/Optimizations/Clean-up
 ASID/VMID support
 Increase hfence granularity
 Improve 2nd-stage translation data structures (e.g. dedicated guest physical address TLB)
 Software:
 Ad hoc testing
 Bao Hypervisor
 Xvisor
ESRGv3 RISC-V Summit 20
PLIC H-Extension
19
ESRGv3
01
02 03
 Main requirements:
 minimal design
 direct injection of physical interrupts for the active guest
 no traps on claim/complete
 mix of physical and virtual interrupts
 Extra GEILEN VS-contexts per physical hart
 Hypervisor must trap-and-emulate VS-context
priority and enable registers.
 Hypervisor gives guests direct access to VS-
context’s claim/complete registers.
 Virtual interrupts are injected by writing to virtual
interrupt injection registers (VIIR) which can be
grouped.
ESRGv3 RISC-V Summit 20
02
PLIC
RISC-V
Hart 0
RISC-V
Hart 1
RISC-V
Hart n
M-mode External Interrupt
S-mode External Interrupt
VS-mode External Interrupt 0
VS-mode GEILEN-1
* The PLIC itself might be deprecated as a new standard interrupt controller is
in the workings.
https://github.com/josecm/riscv-plic-spec/tree/virt
Cache and Bandwidth Partitioning
20
ESRGv3
 Software-based techniques:
 Increases TCB
 High Overheads
 Coarse-grained
 E.g.: page coloring, PMU event based throttling
 Cache Partitioning:
 Per bus-master way-locking
 Lightweight modification to eviction circuit
 Memory bandwidth throttling:
 Bandwidth regulation unit (BRU)
 Per partition memory bandwidth budgets
ESRGv3 RISC-V Summit 20
Adapted from: "BRU: Bandwidth Regulation Unit for Real-
Time Multicore Processors,". F. Farshchi, Q. Huang and H.
Yun. RTAS 2020
Evaluation
Tests, experiments, and results
Experimental Setup
22
ESRGv3
Hardware
▪ Hexa-core rocket
▪ 3.2GHz
▪ 16 KB iL1$ and dL1$
▪ 8-way, 512 KB unified L2$ w/
way-locking
▪ Plic Virt extensions
▪ BRU
System Configurations
▪ Bare-metal / no hypervisor (bare)
▪ Single guest (solo)
▪ Interference (interf)
▪ Partitioning (solo+part)
▪ Partitioning w/ Interference (interf+part)
Metrics
▪ Performance Overhead
▪ Interrupt Latency
RISC-V Summit 20
Software Stack
▪ OpenSBI
▪ Bao Hypervisor
▪ Linux OS (VM)
▪ Baremetal App (VMs)
Memory Resource
Partitioning
▪ 4 L2$ ways
▪ 1800 MiB/s
Performance Overhead
23
ESRGv3
ESRGv3 RISC-V Summit 20
▪ MiBench Benchmark
Suite
▪ Automotive subset
▪ Relative to bare
▪ Bare absolute values
▪ Higher is worse
▪ Negligible variance
Hosted execution brings non-negligible overheads (2 to 6%) . We believe this is mainly due to
high cost of tick timer handling and non-optimized two-stage translation
Memory subsystem interference has performance impacts from 5% to 70%
Cache and memory bandwidth partition mitigations significantly reduce interference (1 to
23%) but not completely
Interrupt Latency
24
ESRGv3
ESRGv3 RISC-V Summit 20
▪ Custom benchmark
▪ Auto-Reload timer at 100 Hz
▪ Absolute time in ns
▪ L1 Instruction cache
invalidated at each tick
Trap-and-emulate approach introduces an extra 650 ns (≈800%) in guest average interrupt latency
Interference increases latency but can be somewhat attenuated by memory resource
partitioning
Direct interrupt injection keeps native latency and is not very susceptible to the effects of interference
Conclusion
Final thoughts and Takeaways
We have presented the first public implementation
valuation of the hypervisor extensions in a RISC-V
27
ESRGv3
 No "real" silicon with H-extension yet
 probably not for the foreseeable future
 Static Partitioning “Virtualization”
 M-mode = hypervisor
 PMP configuration per hart
 PLIC emulation
 IOPMP
 Bao porting
 WiP version @ PolarFire Icicle (Renode)
 Virtualization for RISC-V “as of today”
 Extended platform support
ESRGv3 RISC-V Summit 20
But… do we
really need it ?!
TAKEAWAYS
28
• Current state of the RISC-V
hypervisor extension
specification
• First implementation of the
hypervisor extensions in a
RISC-V core
• Static partitioning
virtualization and what
hardware supports it needs
The spec is close to freeze but we
encourage the community to
contribute
1
There is a need for additional
implementations in other RISC-V
cores
2
There is a need to define standard
extensions that specify memory
resource partition interfaces and
IOMMUs
3
ESRGv3 RISC-V Summit
THANK YOU!
jose.martins@dei.uminho.pt
LinkedIn - https://www.linkedin.com/in/josecmar/
Twitter - https://twitter.com/josecarmartins
Github - https://github.com/josecm
sandro.pinto@dei.uminho.pt
LinkedIn - https://www.linkedin.com/in/sandro2pinto
Twitter - https://twitter.com/sandro2pinto
Github - https://github.com/sandro2pinto/
Q&A
https://github.com/bao-project/bao-hypervisor
https://github.com/josecm/rocket-chip/tree/hyp

More Related Content

What's hot

qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...Adrian Huang
 
Linux Kernel Image
Linux Kernel ImageLinux Kernel Image
Linux Kernel Image艾鍗科技
 
SFO15-TR9: PSCI, ACPI (and UEFI to boot)
SFO15-TR9: PSCI, ACPI (and UEFI to boot)SFO15-TR9: PSCI, ACPI (and UEFI to boot)
SFO15-TR9: PSCI, ACPI (and UEFI to boot)Linaro
 
Memory Compaction in Linux Kernel.pdf
Memory Compaction in Linux Kernel.pdfMemory Compaction in Linux Kernel.pdf
Memory Compaction in Linux Kernel.pdfAdrian Huang
 
/proc/irq/<irq>/smp_affinity
/proc/irq/<irq>/smp_affinity/proc/irq/<irq>/smp_affinity
/proc/irq/<irq>/smp_affinityTakuya ASADA
 
Linux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBLinux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBshimosawa
 
Slab Allocator in Linux Kernel
Slab Allocator in Linux KernelSlab Allocator in Linux Kernel
Slab Allocator in Linux KernelAdrian Huang
 
Memory Mapping Implementation (mmap) in Linux Kernel
Memory Mapping Implementation (mmap) in Linux KernelMemory Mapping Implementation (mmap) in Linux Kernel
Memory Mapping Implementation (mmap) in Linux KernelAdrian Huang
 
Function Level Analysis of Linux NVMe Driver
Function Level Analysis of Linux NVMe DriverFunction Level Analysis of Linux NVMe Driver
Function Level Analysis of Linux NVMe Driver인구 강
 
QEMU Disk IO Which performs Better: Native or threads?
QEMU Disk IO Which performs Better: Native or threads?QEMU Disk IO Which performs Better: Native or threads?
QEMU Disk IO Which performs Better: Native or threads?Pradeep Kumar
 
qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...
qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...
qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...Adrian Huang
 
Kvm and libvirt
Kvm and libvirtKvm and libvirt
Kvm and libvirtplarsen67
 
HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)Linaro
 
Launch the First Process in Linux System
Launch the First Process in Linux SystemLaunch the First Process in Linux System
Launch the First Process in Linux SystemJian-Hong Pan
 
Boosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uringBoosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uringShapeBlue
 
Qemu device prototyping
Qemu device prototypingQemu device prototyping
Qemu device prototypingYan Vugenfirer
 
Introduction to open_sbi
Introduction to open_sbiIntroduction to open_sbi
Introduction to open_sbiNylon
 
Linux Kernel Module - For NLKB
Linux Kernel Module - For NLKBLinux Kernel Module - For NLKB
Linux Kernel Module - For NLKBshimosawa
 

What's hot (20)

qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
qemu + gdb: The efficient way to understand/debug Linux kernel code/data stru...
 
Linux Kernel Image
Linux Kernel ImageLinux Kernel Image
Linux Kernel Image
 
SFO15-TR9: PSCI, ACPI (and UEFI to boot)
SFO15-TR9: PSCI, ACPI (and UEFI to boot)SFO15-TR9: PSCI, ACPI (and UEFI to boot)
SFO15-TR9: PSCI, ACPI (and UEFI to boot)
 
Memory Compaction in Linux Kernel.pdf
Memory Compaction in Linux Kernel.pdfMemory Compaction in Linux Kernel.pdf
Memory Compaction in Linux Kernel.pdf
 
/proc/irq/<irq>/smp_affinity
/proc/irq/<irq>/smp_affinity/proc/irq/<irq>/smp_affinity
/proc/irq/<irq>/smp_affinity
 
Linux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKBLinux Kernel Booting Process (1) - For NLKB
Linux Kernel Booting Process (1) - For NLKB
 
Slab Allocator in Linux Kernel
Slab Allocator in Linux KernelSlab Allocator in Linux Kernel
Slab Allocator in Linux Kernel
 
Memory Mapping Implementation (mmap) in Linux Kernel
Memory Mapping Implementation (mmap) in Linux KernelMemory Mapping Implementation (mmap) in Linux Kernel
Memory Mapping Implementation (mmap) in Linux Kernel
 
Function Level Analysis of Linux NVMe Driver
Function Level Analysis of Linux NVMe DriverFunction Level Analysis of Linux NVMe Driver
Function Level Analysis of Linux NVMe Driver
 
QEMU Disk IO Which performs Better: Native or threads?
QEMU Disk IO Which performs Better: Native or threads?QEMU Disk IO Which performs Better: Native or threads?
QEMU Disk IO Which performs Better: Native or threads?
 
Qemu
QemuQemu
Qemu
 
qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...
qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...
qemu + gdb + sample_code: Run sample code in QEMU OS and observe Linux Kernel...
 
Kvm and libvirt
Kvm and libvirtKvm and libvirt
Kvm and libvirt
 
HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)HKG15-107: ACPI Power Management on ARM64 Servers (v2)
HKG15-107: ACPI Power Management on ARM64 Servers (v2)
 
Launch the First Process in Linux System
Launch the First Process in Linux SystemLaunch the First Process in Linux System
Launch the First Process in Linux System
 
Boosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uringBoosting I/O Performance with KVM io_uring
Boosting I/O Performance with KVM io_uring
 
Qemu device prototyping
Qemu device prototypingQemu device prototyping
Qemu device prototyping
 
Linux Network Stack
Linux Network StackLinux Network Stack
Linux Network Stack
 
Introduction to open_sbi
Introduction to open_sbiIntroduction to open_sbi
Introduction to open_sbi
 
Linux Kernel Module - For NLKB
Linux Kernel Module - For NLKBLinux Kernel Module - For NLKB
Linux Kernel Module - For NLKB
 

Similar to Static partitioning virtualization on RISC-V

2011-11-03 Intelligence Community Cloud Users Group
2011-11-03 Intelligence Community Cloud Users Group2011-11-03 Intelligence Community Cloud Users Group
2011-11-03 Intelligence Community Cloud Users GroupShawn Wells
 
Project ACRN hypervisor introduction
Project ACRN hypervisor introduction Project ACRN hypervisor introduction
Project ACRN hypervisor introduction Project ACRN
 
HiPEAC 2022-DL4IoT workshop_René Griessl presentation
HiPEAC 2022-DL4IoT workshop_René Griessl presentationHiPEAC 2022-DL4IoT workshop_René Griessl presentation
HiPEAC 2022-DL4IoT workshop_René Griessl presentationVEDLIoT Project
 
OVHcloud Hosted Private Cloud Platform Network use cases with VMware NSX
OVHcloud Hosted Private Cloud Platform Network use cases with VMware NSXOVHcloud Hosted Private Cloud Platform Network use cases with VMware NSX
OVHcloud Hosted Private Cloud Platform Network use cases with VMware NSXOVHcloud
 
Summit 16: How to Compose a New OPNFV Solution Stack?
Summit 16: How to Compose a New OPNFV Solution Stack?Summit 16: How to Compose a New OPNFV Solution Stack?
Summit 16: How to Compose a New OPNFV Solution Stack?OPNFV
 
Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...
Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...
Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...RISC-V International
 
DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...
DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...
DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...Jim St. Leger
 
SemiDynamics new family of High Bandwidth Vector-capable Cores
SemiDynamics new family of High Bandwidth Vector-capable CoresSemiDynamics new family of High Bandwidth Vector-capable Cores
SemiDynamics new family of High Bandwidth Vector-capable CoresRISC-V International
 
Devconf2017 - Can VMs networking benefit from DPDK
Devconf2017 - Can VMs networking benefit from DPDKDevconf2017 - Can VMs networking benefit from DPDK
Devconf2017 - Can VMs networking benefit from DPDKMaxime Coquelin
 
“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...
“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...
“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...Edge AI and Vision Alliance
 
HiPEAC-CSW 2022_Kevin Mika presentation
HiPEAC-CSW 2022_Kevin Mika presentationHiPEAC-CSW 2022_Kevin Mika presentation
HiPEAC-CSW 2022_Kevin Mika presentationVEDLIoT Project
 
Virtualization Architecture & KVM
Virtualization Architecture & KVMVirtualization Architecture & KVM
Virtualization Architecture & KVMPradeep Kumar
 
Scaling the Container Dataplane
Scaling the Container Dataplane Scaling the Container Dataplane
Scaling the Container Dataplane Michelle Holley
 
See what happened with real time kvm when building real time cloud pezhang@re...
See what happened with real time kvm when building real time cloud pezhang@re...See what happened with real time kvm when building real time cloud pezhang@re...
See what happened with real time kvm when building real time cloud pezhang@re...LinuxCon ContainerCon CloudOpen China
 
Tungsten Fabric Overview
Tungsten Fabric OverviewTungsten Fabric Overview
Tungsten Fabric OverviewMichelle Holley
 

Similar to Static partitioning virtualization on RISC-V (20)

2011-11-03 Intelligence Community Cloud Users Group
2011-11-03 Intelligence Community Cloud Users Group2011-11-03 Intelligence Community Cloud Users Group
2011-11-03 Intelligence Community Cloud Users Group
 
Project ACRN hypervisor introduction
Project ACRN hypervisor introduction Project ACRN hypervisor introduction
Project ACRN hypervisor introduction
 
HiPEAC 2022-DL4IoT workshop_René Griessl presentation
HiPEAC 2022-DL4IoT workshop_René Griessl presentationHiPEAC 2022-DL4IoT workshop_René Griessl presentation
HiPEAC 2022-DL4IoT workshop_René Griessl presentation
 
Andes RISC-V processor solutions
Andes RISC-V processor solutionsAndes RISC-V processor solutions
Andes RISC-V processor solutions
 
OVHcloud Hosted Private Cloud Platform Network use cases with VMware NSX
OVHcloud Hosted Private Cloud Platform Network use cases with VMware NSXOVHcloud Hosted Private Cloud Platform Network use cases with VMware NSX
OVHcloud Hosted Private Cloud Platform Network use cases with VMware NSX
 
Решения NFV в контексте операторов связи
Решения NFV в контексте операторов связиРешения NFV в контексте операторов связи
Решения NFV в контексте операторов связи
 
Summit 16: How to Compose a New OPNFV Solution Stack?
Summit 16: How to Compose a New OPNFV Solution Stack?Summit 16: How to Compose a New OPNFV Solution Stack?
Summit 16: How to Compose a New OPNFV Solution Stack?
 
Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...
Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...
Esperanto accelerates machine learning with 1000+ low power RISC-V cores on a...
 
DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...
DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...
DPDK Summit - 08 Sept 2014 - Futurewei - Jun Xu - Revisit the IP Stack in Lin...
 
Simplify Networking for Containers
Simplify Networking for ContainersSimplify Networking for Containers
Simplify Networking for Containers
 
SemiDynamics new family of High Bandwidth Vector-capable Cores
SemiDynamics new family of High Bandwidth Vector-capable CoresSemiDynamics new family of High Bandwidth Vector-capable Cores
SemiDynamics new family of High Bandwidth Vector-capable Cores
 
Devconf2017 - Can VMs networking benefit from DPDK
Devconf2017 - Can VMs networking benefit from DPDKDevconf2017 - Can VMs networking benefit from DPDK
Devconf2017 - Can VMs networking benefit from DPDK
 
“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...
“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...
“Open Standards: Powering the Future of Embedded Vision,” a Presentation from...
 
HiPEAC-CSW 2022_Kevin Mika presentation
HiPEAC-CSW 2022_Kevin Mika presentationHiPEAC-CSW 2022_Kevin Mika presentation
HiPEAC-CSW 2022_Kevin Mika presentation
 
5 kvm arm
5 kvm arm5 kvm arm
5 kvm arm
 
Virtualization Architecture & KVM
Virtualization Architecture & KVMVirtualization Architecture & KVM
Virtualization Architecture & KVM
 
Contrail Enabler for agile cloud services
Contrail Enabler for agile cloud servicesContrail Enabler for agile cloud services
Contrail Enabler for agile cloud services
 
Scaling the Container Dataplane
Scaling the Container Dataplane Scaling the Container Dataplane
Scaling the Container Dataplane
 
See what happened with real time kvm when building real time cloud pezhang@re...
See what happened with real time kvm when building real time cloud pezhang@re...See what happened with real time kvm when building real time cloud pezhang@re...
See what happened with real time kvm when building real time cloud pezhang@re...
 
Tungsten Fabric Overview
Tungsten Fabric OverviewTungsten Fabric Overview
Tungsten Fabric Overview
 

More from RISC-V International

London Open Source Meetup for RISC-V
London Open Source Meetup for RISC-VLondon Open Source Meetup for RISC-V
London Open Source Meetup for RISC-VRISC-V International
 
Ziptillion boosting RISC-V with an efficient and os transparent memory comp...
Ziptillion   boosting RISC-V with an efficient and os transparent memory comp...Ziptillion   boosting RISC-V with an efficient and os transparent memory comp...
Ziptillion boosting RISC-V with an efficient and os transparent memory comp...RISC-V International
 
Standardizing the tee with global platform and RISC-V
Standardizing the tee with global platform and RISC-VStandardizing the tee with global platform and RISC-V
Standardizing the tee with global platform and RISC-VRISC-V International
 
Semi dynamics high bandwidth vector capable RISC-V cores
Semi dynamics high bandwidth vector capable RISC-V coresSemi dynamics high bandwidth vector capable RISC-V cores
Semi dynamics high bandwidth vector capable RISC-V coresRISC-V International
 
Reverse Engineering of Rocket Chip
Reverse Engineering of Rocket ChipReverse Engineering of Rocket Chip
Reverse Engineering of Rocket ChipRISC-V International
 
RISC-V NOEL-V - A new high performance RISC-V Processor Family
RISC-V NOEL-V - A new high performance RISC-V Processor FamilyRISC-V NOEL-V - A new high performance RISC-V Processor Family
RISC-V NOEL-V - A new high performance RISC-V Processor FamilyRISC-V International
 
RISC-V 30910 kassem_ summit 2020 - so_c_gen
RISC-V 30910 kassem_ summit 2020 - so_c_genRISC-V 30910 kassem_ summit 2020 - so_c_gen
RISC-V 30910 kassem_ summit 2020 - so_c_genRISC-V International
 
RISC-V 30907 summit 2020 joint picocom_mentor
RISC-V 30907 summit 2020 joint picocom_mentorRISC-V 30907 summit 2020 joint picocom_mentor
RISC-V 30907 summit 2020 joint picocom_mentorRISC-V International
 
RISC-V 30906 hex five multi_zone iot firmware
RISC-V 30906 hex five multi_zone iot firmwareRISC-V 30906 hex five multi_zone iot firmware
RISC-V 30906 hex five multi_zone iot firmwareRISC-V International
 
RISC-V 30946 manuel_offenberg_v3_notes
RISC-V 30946 manuel_offenberg_v3_notesRISC-V 30946 manuel_offenberg_v3_notes
RISC-V 30946 manuel_offenberg_v3_notesRISC-V International
 
RISC-V software state of the union
RISC-V software state of the unionRISC-V software state of the union
RISC-V software state of the unionRISC-V International
 
Ripes tracking computer architecture throught visual and interactive simula...
Ripes   tracking computer architecture throught visual and interactive simula...Ripes   tracking computer architecture throught visual and interactive simula...
Ripes tracking computer architecture throught visual and interactive simula...RISC-V International
 

More from RISC-V International (20)

WD RISC-V inliner work effort
WD RISC-V inliner work effortWD RISC-V inliner work effort
WD RISC-V inliner work effort
 
RISC-V Zce Extension
RISC-V Zce ExtensionRISC-V Zce Extension
RISC-V Zce Extension
 
RISC-V Online Tutor
RISC-V Online TutorRISC-V Online Tutor
RISC-V Online Tutor
 
London Open Source Meetup for RISC-V
London Open Source Meetup for RISC-VLondon Open Source Meetup for RISC-V
London Open Source Meetup for RISC-V
 
RISC-V Introduction
RISC-V IntroductionRISC-V Introduction
RISC-V Introduction
 
Ziptillion boosting RISC-V with an efficient and os transparent memory comp...
Ziptillion   boosting RISC-V with an efficient and os transparent memory comp...Ziptillion   boosting RISC-V with an efficient and os transparent memory comp...
Ziptillion boosting RISC-V with an efficient and os transparent memory comp...
 
Standardizing the tee with global platform and RISC-V
Standardizing the tee with global platform and RISC-VStandardizing the tee with global platform and RISC-V
Standardizing the tee with global platform and RISC-V
 
Semi dynamics high bandwidth vector capable RISC-V cores
Semi dynamics high bandwidth vector capable RISC-V coresSemi dynamics high bandwidth vector capable RISC-V cores
Semi dynamics high bandwidth vector capable RISC-V cores
 
Security and functional safety
Security and functional safetySecurity and functional safety
Security and functional safety
 
Reverse Engineering of Rocket Chip
Reverse Engineering of Rocket ChipReverse Engineering of Rocket Chip
Reverse Engineering of Rocket Chip
 
RISC-V NOEL-V - A new high performance RISC-V Processor Family
RISC-V NOEL-V - A new high performance RISC-V Processor FamilyRISC-V NOEL-V - A new high performance RISC-V Processor Family
RISC-V NOEL-V - A new high performance RISC-V Processor Family
 
RISC-V 30910 kassem_ summit 2020 - so_c_gen
RISC-V 30910 kassem_ summit 2020 - so_c_genRISC-V 30910 kassem_ summit 2020 - so_c_gen
RISC-V 30910 kassem_ summit 2020 - so_c_gen
 
RISC-V 30908 patra
RISC-V 30908 patraRISC-V 30908 patra
RISC-V 30908 patra
 
RISC-V 30907 summit 2020 joint picocom_mentor
RISC-V 30907 summit 2020 joint picocom_mentorRISC-V 30907 summit 2020 joint picocom_mentor
RISC-V 30907 summit 2020 joint picocom_mentor
 
RISC-V 30906 hex five multi_zone iot firmware
RISC-V 30906 hex five multi_zone iot firmwareRISC-V 30906 hex five multi_zone iot firmware
RISC-V 30906 hex five multi_zone iot firmware
 
RISC-V 30946 manuel_offenberg_v3_notes
RISC-V 30946 manuel_offenberg_v3_notesRISC-V 30946 manuel_offenberg_v3_notes
RISC-V 30946 manuel_offenberg_v3_notes
 
RISC-V software state of the union
RISC-V software state of the unionRISC-V software state of the union
RISC-V software state of the union
 
Ripes tracking computer architecture throught visual and interactive simula...
Ripes   tracking computer architecture throught visual and interactive simula...Ripes   tracking computer architecture throught visual and interactive simula...
Ripes tracking computer architecture throught visual and interactive simula...
 
Porting tock to open titan
Porting tock to open titanPorting tock to open titan
Porting tock to open titan
 
Open j9 jdk on RISC-V
Open j9 jdk on RISC-VOpen j9 jdk on RISC-V
Open j9 jdk on RISC-V
 

Recently uploaded

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfOverkill Security
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamUiPathCommunity
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKJago de Vreede
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusZilliz
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 

Recently uploaded (20)

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 

Static partitioning virtualization on RISC-V

  • 1. Static Partitioning Virtualization on RISC-V José Martins and Sandro Pinto RISC-V Summit @ Virtual December 8th, 2020
  • 2. Agenda Introduction Motivation and Background 01 RISC-V Virtualization RISC-V virtualization in a nutshell 02 RISC-V H-Extension Implementation & enhancements 03 Evaluation Tests, experiments, and results 04 Conclusion Final thoughts and Takeaways 05
  • 4. Mixed-Criticality 4 ESRGv3 RISC-V Summit 20 • High Complexity • Multiple Subsystems • Heterogeneous Software Stacks (RTOS, GPOS) • Different Criticality Levels • Size, Weight, Power and Cost (SWaP-C) Automotive Industrial Automation
  • 5. Embedded Virtualization 5 ESRGv3 ESRGv3 RISC-V Summit 20 Consolidation Size Weight Power Cost Low Engineering Cost Full-Virtualization allows direct porting of guest OSs Fault Containment Sandboxed Enviroments Performance Low Virtualization Overhead Close to Native Performance Security Small TCB Side-channel TEE support Open Design Real-time Low latencies Determinism/Predictability Freedom-from-interference
  • 6. Traditional Hypervisors 6 ESRGv3 ▪ Not designed for embedded/MCS: ▪ Although retrofitted with success ▪ High-overhead IO: ▪ Emulated ▪ Para-virtualization/Backend-drivers ▪ Large Code Base : ▪ Hosted hypervisor ▪ Privileged VMs run large monolithic OSs (typically Linux) part of TCB. ESRGv3 RISC-V Summit 20
  • 7. Static Partitioning Virtualization 7 ESRGv3 Jailhouse  Static Partitioning:  Thin configuration/partition layer  1:1 vCPU-to-pCPU mapping  Static memory assignment  Device Pass-through  Hardware interrupts  Jailhouse:  Needs “root cell” to boot and manage VMs  Large boot time  Xen Dom0-less*:  DomUs may boot w/o Dom0  Direct Device assignment Dom0-less ESRGv3 RISC-V Summit 20 * https://www.youtube.com/watch?v=OrtV6gyHW74
  • 8. Bao Overview 8 ESRGv3 01 02 03  Type-1 / Bare-metal  Static Partitioning:  1:1 vCPU-to-pCPU mapping  Static memory assignment  Device Pass-through  Hardware-assisted:  2nd-stage translation  Interrupt virtualization support  IOMMU  Dependencies:  No external libraries / privileged VMs  Small TCB (~7K SLoC)  Real-time & Security:  Predictability / Freedom-from-interference  Side-channels / TEE support ESRGv3 RISC-V Summit 20 José Martins, Adriano Tavares, Marco Solieri, Marko Bertogna, and Sandro Pinto. "Bao: A Lightweight Static Partitioning Hypervisor for Modern Multi-Core Embedded Systems". In NG-RES 2020 https://drops.dagstuhl.de/opus/volltexte/2020/11779/
  • 9. Bao Hypervisor Support 9 ESRGv3 01 03  Architectures:  Armv8-A  RISC-V (v0.6.1 Hyp Spec.)  Platforms:  Zynq US+ (ZCUx and Ultra96)  HiSilicon96 (Hikey96)  NXP i.MX8  Nvidia Tegra TX2  QEMU  Rocket @ ZCU  Firmware:  Arm Trusted Firmware (PSCI) on Arm  Supervisor Binary Interface (SBI) on RISC-V  U-boot  Guests:  Bare-metal  Linux / Android  RTOSs (FreeRTOS, Erika) ESRGv3 RISC-V Summit 20
  • 11. Hypervisor Extension 11 ESRGv3  Designed for type-1 and type-2 hypervisors  Additional execution modes  HS-mode (hypervisor-extended supervisor)  VS-mode & VU-mode  Additional CSR registers:  HS-mode CSRs for hypervisor capabilities (e.g., hstatus)  HS-mode CSRs for accessing Guest/VM state (e.g., vsstatus)  Two-Stage MMU:  Stage 1: VS-mode page table (GVA -> GPA)  Stage 2: HS-mode guest page table (GPA -> HPA) ESRGv3 RISC-V Summit 20 https://github.com/riscv/riscv-isa-manual/releases/latest
  • 12. Hypervisor Extension 12 ESRGv3 ESRGv3 RISC-V Summit 20 Hypervisor Firmware (SBI) Decreasing Privilege level M Guest OS Guest User Space Host User Space Virtualised Environment Non-virtualised Environment HS VS Adapted from: Alistair Francis (WD), “Developing the RISC-V Hypervisor Extensions in QEMU”, Embedded Linux Conference Europe, 2019 VU M HS U
  • 13. Spec Status 13 ESRGv3 ESRGv3 RISC-V Summit 20  Currently version 0.6.1  Feedback from open source projects  Contributions from organizations and individuals  H-Extension spec close to freeze state  Hypervisor “group” (join RISC-V Hypervisor sync-up calls!)  Function completeness (KVM & Xvisor)  RTL implementations (we have contributed with one )  KVM and Xvisor running on FPGA implementation (we have ran Xvisor on an FPGA )  Open source projects support:  QEMU (v0.6.1)  KVM and Xvisor (v0.6.1)
  • 14. RISC-V Hypervisors 14 ESRGv3  KVM:  Type-2 hypervisor, Linux-based architecture, open-source  Enterprise virtualization setups (datacenters and private clouds)  https://github.com/kvm-riscv/linux  Xvisor:  Type-1 hypervisor, monolithic architecture, open-source  Embedded systems with soft real-time requirements  https://github.com/avpatel/xvisor-next  Bao:  Type-1 hypervisor, static partitioning architecture, open-source  Mixed-criticality systems with strong real-time and security requirements  https://github.com/bao-project/bao-hypervisor ESRGv3 RISC-V Summit 20
  • 16. Spec Checklist 16 ESRGv3 01 02 03  H-Extension, Version 0.6.1  RV64 and sv39 only  Implemented:  h- and vs- csrs and respective functionality  m- registers extended accordingly  hypervisor load/store instructions  new virtual instruction exception  hfence instructions (limited, flushes complete TLB)  guest external interrupts (w/ PLIC virtualization extension)  Not Implemented:  ASID/VMID support  Transformed Instruction or Pseudoinstruction for htinst/mtinst ESRGv3 RISC-V Summit 20
  • 17. H-Extension Implementation 17 ESRGv3 01 02 03  Available at: https://github.com/josecm/rocket-chip/tree/hyp  Synced with chipyard’s master branch commit of rocket-chip (@1872f5d, 6 months ago)  ~1100 sLOC modifications to rocket-chip. Mainly on:  CSR  PTW  TLB ESRGv3 RISC-V Summit 20
  • 18. H-Extension Implementation 18 ESRGv3 01 02 03  Next Steps:  Refactoring/Optimizations/Clean-up  ASID/VMID support  Increase hfence granularity  Improve 2nd-stage translation data structures (e.g. dedicated guest physical address TLB)  Software:  Ad hoc testing  Bao Hypervisor  Xvisor ESRGv3 RISC-V Summit 20
  • 19. PLIC H-Extension 19 ESRGv3 01 02 03  Main requirements:  minimal design  direct injection of physical interrupts for the active guest  no traps on claim/complete  mix of physical and virtual interrupts  Extra GEILEN VS-contexts per physical hart  Hypervisor must trap-and-emulate VS-context priority and enable registers.  Hypervisor gives guests direct access to VS- context’s claim/complete registers.  Virtual interrupts are injected by writing to virtual interrupt injection registers (VIIR) which can be grouped. ESRGv3 RISC-V Summit 20 02 PLIC RISC-V Hart 0 RISC-V Hart 1 RISC-V Hart n M-mode External Interrupt S-mode External Interrupt VS-mode External Interrupt 0 VS-mode GEILEN-1 * The PLIC itself might be deprecated as a new standard interrupt controller is in the workings. https://github.com/josecm/riscv-plic-spec/tree/virt
  • 20. Cache and Bandwidth Partitioning 20 ESRGv3  Software-based techniques:  Increases TCB  High Overheads  Coarse-grained  E.g.: page coloring, PMU event based throttling  Cache Partitioning:  Per bus-master way-locking  Lightweight modification to eviction circuit  Memory bandwidth throttling:  Bandwidth regulation unit (BRU)  Per partition memory bandwidth budgets ESRGv3 RISC-V Summit 20 Adapted from: "BRU: Bandwidth Regulation Unit for Real- Time Multicore Processors,". F. Farshchi, Q. Huang and H. Yun. RTAS 2020
  • 22. Experimental Setup 22 ESRGv3 Hardware ▪ Hexa-core rocket ▪ 3.2GHz ▪ 16 KB iL1$ and dL1$ ▪ 8-way, 512 KB unified L2$ w/ way-locking ▪ Plic Virt extensions ▪ BRU System Configurations ▪ Bare-metal / no hypervisor (bare) ▪ Single guest (solo) ▪ Interference (interf) ▪ Partitioning (solo+part) ▪ Partitioning w/ Interference (interf+part) Metrics ▪ Performance Overhead ▪ Interrupt Latency RISC-V Summit 20 Software Stack ▪ OpenSBI ▪ Bao Hypervisor ▪ Linux OS (VM) ▪ Baremetal App (VMs) Memory Resource Partitioning ▪ 4 L2$ ways ▪ 1800 MiB/s
  • 23. Performance Overhead 23 ESRGv3 ESRGv3 RISC-V Summit 20 ▪ MiBench Benchmark Suite ▪ Automotive subset ▪ Relative to bare ▪ Bare absolute values ▪ Higher is worse ▪ Negligible variance Hosted execution brings non-negligible overheads (2 to 6%) . We believe this is mainly due to high cost of tick timer handling and non-optimized two-stage translation Memory subsystem interference has performance impacts from 5% to 70% Cache and memory bandwidth partition mitigations significantly reduce interference (1 to 23%) but not completely
  • 24. Interrupt Latency 24 ESRGv3 ESRGv3 RISC-V Summit 20 ▪ Custom benchmark ▪ Auto-Reload timer at 100 Hz ▪ Absolute time in ns ▪ L1 Instruction cache invalidated at each tick Trap-and-emulate approach introduces an extra 650 ns (≈800%) in guest average interrupt latency Interference increases latency but can be somewhat attenuated by memory resource partitioning Direct interrupt injection keeps native latency and is not very susceptible to the effects of interference
  • 26. We have presented the first public implementation valuation of the hypervisor extensions in a RISC-V
  • 27. 27 ESRGv3  No "real" silicon with H-extension yet  probably not for the foreseeable future  Static Partitioning “Virtualization”  M-mode = hypervisor  PMP configuration per hart  PLIC emulation  IOPMP  Bao porting  WiP version @ PolarFire Icicle (Renode)  Virtualization for RISC-V “as of today”  Extended platform support ESRGv3 RISC-V Summit 20 But… do we really need it ?!
  • 28. TAKEAWAYS 28 • Current state of the RISC-V hypervisor extension specification • First implementation of the hypervisor extensions in a RISC-V core • Static partitioning virtualization and what hardware supports it needs The spec is close to freeze but we encourage the community to contribute 1 There is a need for additional implementations in other RISC-V cores 2 There is a need to define standard extensions that specify memory resource partition interfaces and IOMMUs 3 ESRGv3 RISC-V Summit
  • 29. THANK YOU! jose.martins@dei.uminho.pt LinkedIn - https://www.linkedin.com/in/josecmar/ Twitter - https://twitter.com/josecarmartins Github - https://github.com/josecm sandro.pinto@dei.uminho.pt LinkedIn - https://www.linkedin.com/in/sandro2pinto Twitter - https://twitter.com/sandro2pinto Github - https://github.com/sandro2pinto/