Table of Contents
Fetching ...

vNV-Heap: An Ownership-Based Virtually Non-Volatile Heap for Embedded Systems

Markus Elias Gerber, Luis Gerhorst, Ishwar Mudraje, Kai Vogelgesang, Thorsten Herfet, Peter Wägemann

TL;DR

The paper tackles the challenge of persistent state management in intermittently powered embedded systems that lack an MMU. It introduces vNV-Heap, an ownership-based, virtually non-volatile heap that leverages compile-time borrow-checking to provide memory safety, object virtualization, and bounded worst-case energy consumption during checkpoints. Key contributions include the concept of ownership-based virtual memory, a two-layer interface (convenient and guard-based), per-object metadata for dynamic swapping, and an energy-aware evaluation demonstrating improved energy efficiency and predictable performance on an ESP32-C3 with FRAM. The work demonstrates that safe, hardware-agnostic memory management is feasible for reactive intermittent computing, enabling more feature-rich IoT devices with strong resilience to power failures.

Abstract

The Internet of Batteryless Things might revolutionize our understanding of connected devices by harvesting required operational energy from the environment. These systems come with the system-software challenge that the intermittently powered IoT devices have to checkpoint their state in non-volatile memory to later resume with this state when sufficient energy is available. The scarce energy resources demand that only modified data is persisted before a power failure, which requires precise modification tracking. We present vNV-Heap, the first ownership-based virtually Non-Volatile Heap for intermittently powered systems with guaranteed power-failure resilience. The heap exploits ownership systems, a zero-cost (i.e., compile-time) abstraction for example implemented by Rust, to track modifications and virtualize object persistence. To achieve power-failure resilience, our heap is designed and implemented to guarantee bounded operations by static program code analysis: For example, the heap allows for determining a worst-case energy consumption for the operation of persisting modified and currently volatile objects. The evaluation of our open-source implementation on an embedded hardware platform (i.e., ESP32-C3) shows that using our heap abstraction is more energy efficient than existing approaches while also providing runtime guarantees by static worst-case bounds.

vNV-Heap: An Ownership-Based Virtually Non-Volatile Heap for Embedded Systems

TL;DR

The paper tackles the challenge of persistent state management in intermittently powered embedded systems that lack an MMU. It introduces vNV-Heap, an ownership-based, virtually non-volatile heap that leverages compile-time borrow-checking to provide memory safety, object virtualization, and bounded worst-case energy consumption during checkpoints. Key contributions include the concept of ownership-based virtual memory, a two-layer interface (convenient and guard-based), per-object metadata for dynamic swapping, and an energy-aware evaluation demonstrating improved energy efficiency and predictable performance on an ESP32-C3 with FRAM. The work demonstrates that safe, hardware-agnostic memory management is feasible for reactive intermittent computing, enabling more feature-rich IoT devices with strong resilience to power failures.

Abstract

The Internet of Batteryless Things might revolutionize our understanding of connected devices by harvesting required operational energy from the environment. These systems come with the system-software challenge that the intermittently powered IoT devices have to checkpoint their state in non-volatile memory to later resume with this state when sufficient energy is available. The scarce energy resources demand that only modified data is persisted before a power failure, which requires precise modification tracking. We present vNV-Heap, the first ownership-based virtually Non-Volatile Heap for intermittently powered systems with guaranteed power-failure resilience. The heap exploits ownership systems, a zero-cost (i.e., compile-time) abstraction for example implemented by Rust, to track modifications and virtualize object persistence. To achieve power-failure resilience, our heap is designed and implemented to guarantee bounded operations by static program code analysis: For example, the heap allows for determining a worst-case energy consumption for the operation of persisting modified and currently volatile objects. The evaluation of our open-source implementation on an embedded hardware platform (i.e., ESP32-C3) shows that using our heap abstraction is more energy efficient than existing approaches while also providing runtime guarantees by static worst-case bounds.

Paper Structure

This paper contains 29 sections, 9 figures.

Figures (9)

  • Figure 1: Possible object states in vNV-Heap: Virtual objects can be swapped-out, resident, or modified. If the application owns any access guards, the object is pinned in RAM.
  • Figure 2: The evaluation system consists of an SPI-connected MB85RS4MT FRAM module with an ESP32-C3.
  • Figure 3: Latency for accessing an object in the vNV-Heap and with a module-based swapping approach (baseline). Both systems are configured such that the size of the largest resident object is 1. Note that the scale for the best-case differs from the other two scales.
  • Figure 4: The average latency for inserting one element and then removing the least recent one from a queue with a specific initial length. The volatile RAM usable by each queue implementation is limited by 4.
  • Figure 5: The measurement-based WCEC for persisting the vNV-Heap compared to unmanaged RAM.
  • ...and 4 more figures