Benchmark · 2026-11-22
How CircuitTwin Caught 24/26 STM32 Bugs While Passing 17/17 Working Builds
A firmware simulator has two jobs. Catch broken firmware, and let working firmware pass. We tested 43 real STM32F407 ELF images on CircuitTwin, Renode v1.17.0, and QEMU 10.0.13 to measure both.
The 43-ELF test set
Our public MIT harness (github.com/CircuitTwin/agent-bench) contains 17 STM32F407 firmware tasks. Each task has one working baseline binary (v0) and one or more buggy variants (26 buggy ELFs total). Every binary runs untouched on all three emulators offline and prints a CT-BENCH pass or fail line.
| Platform | Buggy builds caught | Working builds passed | Distinct catches (differs from v0) |
|---|---|---|---|
| CircuitTwin (ct 0.1.0) | 24 of 26 | 17 of 17 | 24 |
| Renode v1.17.0 (default) | 12 of 26 | 15 of 17 | 11 |
| QEMU 10.0.13 | 19 of 26 | 10 of 17 | 8 |
Why working builds broke on QEMU and Renode
Raw catch counts hide a serious problem. If an emulator breaks the working v0 build, it will also fail every buggy version of that task for the exact same reason.
QEMU broke 7 of 17 working builds (passing only 10 of 17). Its olimex-stm32-h405 machine leaves STM32 GPIO, DMA, and I2C unimplemented, so reads return zero and writes disappear silently. Because those 7 working baselines already failed, 11 of QEMU’s 19 raw catches repeated the same v0 failure, leaving 8 distinct bug catches.
Renode v1.17.0 did much better on working builds, passing 15 of 17. Its two broken working builds were i2c_nack v0 (no SR1.AF flag when addressing an unregistered device) and psc v0 (hardcoded SysTick and TIM3 frequencies decoupled from the 16 MHz HSI clock). At default 100 MIPS it also skipped RCC clock-gating checks, GPIO MODER checks, DMA FIFO errors, and UART baud mismatches. Setting cpu PerformanceInMips 16 manually caught one extra watchdog bug (wdg v1), moving Renode to 13 of 26.
What CircuitTwin caught and what it missed
CircuitTwin passed all 17 of 17 working builds and caught 24 of 26 buggy builds. Every catch produced a signal distinct from the working baseline.
We publish our 2 misses openly on the agent benchmark page:
i2c_nackv2: Both CircuitTwin and Renode missed this specific I2C edge case.reset_valsv1: Default zeroed SRAM hid an uninitialized-RAM read on all three platforms. Passing--uninitialized-memory seeded:1toct runcatches it, though we keep that outside the default 24/26 count.
Run the exact harness yourself
Every SHA-256 hash, runner binary digest, and per-task log sits in our published evidence record. Clone the repo and verify every number locally:
git clone https://github.com/CircuitTwin/agent-bench
cd agent-bench
ct run --json --board stm32f4-discovery build/clk_gate_v1.elf