> Snapshot of projects/fog-crypto-core/performance/README.md — 28 Nov 2026

# Fog-Crypto Core — Performance measurement (M&A)

Measurement & Analysis plan for CMMI-DEV v2.0, Level 3. Closes the audit and engineering reviews
#1–#4. Revision 1.4.

## Target KPIs (frozen in `requirements/REQ.md`)

- **REQ-FOG-PERF-001** — CPU ÷ 10: ≥ 85 % → ≤ 8.5 % (1500 B); 64-byte stress ≤ 400 cycles/packet.
- **REQ-FOG-PERF-002** — line rate: ≥ 1.488 Mpps @ 64 B, ≥ 975 Mbps L2 goodput @ 1518 B (1 GbE).
- **REQ-FOG-PERF-003** — latency: AES ≤ 100 cycles; crypto end-to-end ≤ 20 µs; sensor
  `PL_PS_IRQ0` ≤ 2 µs (≤ 50 µs to userspace handler).
- **REQ-FOG-HW-002/003** — ≤ 70 % ZU3EG resources (≤ 49 392 LUTs / ≤ 252 DSP / ≤ 151 BRAM), WNS
  ≥ 0 ns @ 250 MHz; crypto enclave ≤ 15 000 LUTs (OOC gate).

## Measurement protocol

- **Scenario**: continuous 1 GbE crypto stream (64 B and 1518 B mixes) + simultaneous ADC sensor
  stream with threshold injections.
- **Reference**: software AES-256-GCM (ARMv8 Crypto Extensions) before offload; hardware after.
- **Iterations**: ≥ 10 runs per configuration, reporting p50 / p95 / max.
- **PMU counters**: `CPU_CYCLES`, `L2D_CACHE_REFILL`, `L2D_CACHE_WB` confirm ≤ 400 cycles/pkt and
  ≤ 0.25 refill/pkt (OCM-resident or batched B ≥ 8 descriptor rings).

## Expected deliverables

`cpu-offload.md`, `throughput.md`, `latency.md` (crypto **and** sensor IRQ paths),
`utilization-timing.md` (OOC gate on ZU3EG) — each linked from `requirements/RTM.md` and checked
off before any release.
