Skip to main content

Mode notes

Design note

To choose a mode, start with Choosing a mode in the FEMU Manual. The pages in this section are design notes traced through the source.

Choose the interface your experiment needs, then the policies implemented on that path. There are six numeric controller modes. FDP is a placement extension to black-box mode; OpenChannel is included for historical workloads. The CXL SSD is a separate device type, femu-cxl-ssd, not a femu_mode. The manual's mode table is generated from the source and lists every mode and feature, including namespace management, metadata and protection information, and the CXL SSD with its NVMe front end. The table below covers the modes these design notes trace.

Interfacefemu_modePlacement ownerMain experiment path
Black-box1Device FTLBlock workloads, mapping, GC, caches, NAND timing
Zoned3Host zone managementSequential zones, append, reset, resource limits, ZRWA
FDP1 + subsystem FDPHost hints and device placementReclaim-unit handles and FDP collection strategies
Key-value5KV index and value storeKey commands, value programming, compaction
Computational storage4Block FTL plus compute commandsDevice memory, program execution, compute-unit timing
No SSD2No flash placementNVMe software path and optional controller costs
OpenChannel0Compatible host placement stackHistorical physical I/O and chunk management
CXL SSD (manual)-device femu-cxl-ssdDevice cache and FTL behind CXL memoryLoad and store access with SSD timing on cache misses

Choosing a starting point​

For a filesystem or database with an ordinary NVMe block interface, start with black-box. For host placement, choose ZNS when the application manages zone lifetimes, or FDP when it sends placement directives while using a block namespace. KV and CSD require their command-specific clients and probes. NoSSD helps measure the software path without NAND timing.

The implementation guide maps features to their actual paths. The recipe catalog supplies complete configurations and verification steps. Check model scope before treating a configuration as a calibrated device.

Mixed namespaces​

A controller can expose supported modes on different namespaces. For example:

[device]
mode = bbssd
devsz_mb = 6144
namespaces = 3
namespace_modes = bbssd,znssd,nossd
namespace_sizes = 2G,2G,2G

Each namespace has its own backing slice and mode state, but queues, controller threads, and optional link/firmware resources remain shared. FDP and OpenChannel are single-namespace configurations, and a controller takes at most one CSD namespace. The manual's several namespaces page has the size rounding and refusal rules. The INI helper handles QEMU comma escaping; see the complete mixed recipe.

Implementation sources​

Reviewed against FEMU 39a55eeb6. The examples describe this revision; see validation coverage.

  • femu.c: mode dispatch, namespace restrictions, properties
  • nvme.h: numeric mode definitions