Plugin and callback catalog
FastDyn uses several extension mechanisms. A virtual instruction is a named action triggered at a guest PC. A run plugin prepares a feature for a CPU and may generate many internal hooks. Device handlers, physics backends, and campaign drivers have their own interfaces. Similar names do not make them interchangeable configuration namespaces.
This catalog covers the pinned main revision used by the book. For configuration snippets from your checkout, run:
fastdyn help virtuals --no-browse
fastdyn help plugins --no-browse
fastdyn help modifiers --no-browse
fastdyn help device-models --no-browse
plugins currently aliases the virtual/plugin browser. That browser shows definitions carrying public ConfigurationHelp; it does not enumerate every native callback installed by optional backends or generated by a firmware profile. A help entry also does not prove that an optional native library was included in your build.
Public core virtual instructions
These fifteen names appear in both the core native registry and Python's built-in virtual definitions. Configure them with [[CPU.cpuN.virtuals]], at, instruction, and optional args. Names are case-sensitive; raise_irq is a compatibility alias normalized to raiseirq by preparation.
| Exact name | Purpose | Important contract |
|---|---|---|
printreg | Print one register | Argument is the target register number |
debug_log | Emit a guest-event diagnostic | Arguments become a message string |
updatemem | Read/write guest memory | Use its address/direction/length/byte-list grammar |
randstate | Randomize selected state | Register numbers and addresses have different interpretation; do not randomize the PC |
raiseirq | Raise an interrupt | Numeric arguments are exception vectors; symbolic preparation is Cortex-M-specific |
pulseirq | Pulse an interrupt | Requires the appropriate target IRQ semantics |
raise_periodic_irq | Register a repeating interrupt | Optional period is in nanoseconds |
timer_start | Start the legacy timer | Separate from the benchmark timer |
start_budgeting | Enter budget waiting | Intended for an experiment with a controller/budget contract |
benchmark_start | Begin a timing region | Uses host monotonic time |
bench_tick | Count benchmark ticks | Operates on the benchmark state |
benchmark_end | Report a timing region and terminate QEMU | A terminal action, not a passive marker |
dyninst | Copy a host file into guest memory | Changes guest memory at runtime |
dyninst_lib | Load an ELF through the QEMU plugin API | Requires a compatible ELF and loading context |
dumplog | Dump an internal logger buffer | Uses the logger-index/file argument form |
These are registry names, not a promise that every action has identical meaning on every guest architecture. See virtuals and modifiers for argument grammar, register conventions, and same-PC conflicts.
Run-wide plugins
These are the six in-tree RunDefinition names discovered from feature-owned host/preprocessor.py files. Enable them with [CPU.cpuN.plugins.<name>] and enabled = true, then supply the feature's own settings.
| Exact plugin name | Prepared/runtime behavior | Scope and output |
|---|---|---|
function_counter | Select executable function entries and count hits | ELF symbols; functions.tsv, final counts.tsv |
function_tracer | Prepare entry-argument layouts and record calls | Supported DWARF/ABI forms; arguments.tsv, trace.tsv, counts |
variable_watch | Resolve one variable or address range and observe overlapping accesses | Current Thumb/M-profile planner; watch.tsv, events.tsv |
object_sanitizer | Select objects/allocation sites and track supported provenance | Current Thumb/M-profile planner; object lifecycle and violation records |
introspection | Identify supported RTOS hooks and prepare kernel schemas | Adapter-specific task/resource events; schema.txt, activity.jsonl |
world | Prepare a physical-world description and firmware pin bindings | Requires built tools/world native dependency; world state and optional observation |
The first five native modules are included by the normal virtuals/meson.build feature list. World is automatically compiled when the expected header and tools/world/build/libworld_model.so exist. Enabling its TOML table cannot manufacture a missing native runtime.
The narrative guides cover tracing and object checking, RTOS introspection, and World integration.
Internal callbacks belong to their feature
Run plugins may register native callbacks that are implementation details. For example, Function Counter generates function_counter; ObjectSan uses object_sanitizer_alloc_call, object_sanitizer_alloc_return, and object_sanitizer_free; World uses world_digital_out and world_analog_in. Introspection selects numerous RTOS-specific hook names from the firmware.
Configure the owning plugin rather than manually reproducing its schema and internal rules. The callback registry only connects a name to native behavior; it does not supply the prepared manifest, target layout, or correct argument convention by itself. Two plugins that generate different callbacks at the same PC still encounter the dispatcher's one-callback restriction.
Optional mechanisms and their gates
| Mechanism | How it is selected | Build/runtime requirement |
|---|---|---|
| Inline modifiers | CPU modifiers array | Patched target backend; register/width semantics are architecture-specific |
| Specialized inline I/O | [Machine].finline | Static access-map path with explicit backing state and original-instruction handling; see inline device modeling |
| Device handlers | [Device.Models.*] and handler assignments | Device-model build; hardware paths also require libhw |
| Vehicle physics | [FMU], physics options, and controller profiles | PHY=true; FMU=true for FMUs; FLIGHT_CONTROLLERS=true for controller adapters |
| Legacy Gazebo physics | Selected Gazebo backend | PHY=true LIBGZ=true and matching Gazebo dependencies |
| Native firmware fuzzing | Machine fuzzing/coverage settings and a harness | LibAFL or AFLNet build; initialized coverage and snapshot ranges |
| External runtime plugin | Plugin table's source folder | Registered host half and compatible runtime/*.so descriptor/SDK linkage |
| Swarm/campaign orchestration | CLI or downstream driver | Separate worker configuration and dependencies; not a run-plugin name |
The feature browser advertises device-handler names classic, passthrough, elder, twintrace, and unhandled. These are not virtual instruction names. The legacy halucinator/Python embedding path is separately gated and is documented upstream as currently failing to build.
When a native fuzzing build initializes with coverage, it registers assert, fuzz_advance_time, fuzz_snap_point, fuzz_snap_sync_point, fuzz_state_point, fuzz_sync_point, and fuzz_virtual_millis. These are conditional native callbacks, not additional public core definitions. Use the fuzzing harness guide for their lifecycle rather than assuming they exist in the minimal build.
Controller integrations likewise register profile-specific actions such as start_advancing_sim, ins_block_read, write_channel, and bridge_px4_uorb. Their names and ABI expectations belong to the flight-controller integration, not a generic sensor protocol.
Adding a new feature
Register user-facing help beside the feature, keep derived data in artifacts, and declare required capabilities on virtual definitions where applicable. The generic preparation code supplies core, conditionally fuzzing and fmu, plus explicit host-provided capabilities. Build options, available artifacts, target support, and enablement remain separate facts that the feature must handle consistently.
See writing plugins for the supported host/native registration and external-plugin workflow.