# Cohesix Benchmarking ## Release B adoption and integration budgets (M28g) Freeze these limits before running `m28g-adoption-live` and `m28g-integration-live`. The retained 1.1.0-beta Mac and Linux archives are 26,501,100 and 28,513,510 bytes respectively; they are the comparable core download baseline. They contain neither the Release B native installers nor optional QEMU, GPU runtimes or models, so report those downloads separately. The earlier M28f one-question model comparison below is the selected quality and client-latency baseline for that exact question, not a general model score. Count an operator step when the evaluator must choose, enter or confirm an action. Count an intervention when a published step fails and needs an undocumented correction; record expected credential, data and model-licence choices separately. Start the setup clock at the first native installer action; stop it when `coh doctor` identifies the selected endpoint, client and provider correctly. Start the first-work clock after required credentials, target and model/artifact inputs are available; stop only at an independently verified useful result. Keep raw timestamps, download byte counts, every failed attempt and the evaluator's identity and assistance record. | Measure | Frozen Release B limit | | --- | --- | | Core installation on either selected host | At most 30 operator steps, 45 minutes, 100 MiB of package/archive downloads and two undocumented interventions. Explicit optional QEMU, GPU runtimes, models and datasets are measured separately and require an opt-in. | | First useful CUDA result from the installed client | At most 20 minutes after the provisioned target and allowlisted workload are available; the output and original admission identity must pass the independent native verifier. | | PEFT and agent journey quality | Every selected held-out/canary, native deployment and same-input NeMo comparison check must meet its already fixed M28b/M28f criterion; a missing native receipt, refusal or ambiguous result is never counted as success. | | Refusal and recovery | Every negative case returns an explicit bounded reason with no new effect. A host gateway/agent restart must deliver or reconcile the original job within 120 seconds after process readiness, without a fresh effect identity. Queen loss must refuse new effects until a fresh authenticated target identity and authority are established. | | Added protocol control latency | For each mode, compare at least 30 authenticated read/control calls with the same installed gateway and target to direct REST calls in one quiet window. Report p50, p95 and every refusal; protocol p95 may exceed direct REST p95 by at most 100 ms and 25% of direct REST p95, whichever is larger. Do not mix model or provider execution time into this measure. | For the protocol comparison, retain one CSV with `mode,protocol,sample,elapsed_ms,status` and contiguous sample numbers starting at one for each enabled protocol in each mode. Use nearest-rank p95 over the same number of calls in each reported mode. The integration verifier recomputes the p95 from the raw samples and rejects gaps, duplicates, failed calls and samples for disabled protocols. Keep response bodies, request identities and timestamps in the accompanying raw client logs so equal latencies cannot hide different target results. These are acceptance limits, not measurements. The three complete journeys in BUILD_PLAN still require their selected native outcomes, installed clients, GUI launch, rollback/uninstall and a named evaluator's walkthrough. For this sole-developer release, Lukas Bower may evaluate the installation, but must record `independent=false` and report the result as owner-evaluated. The raw attachments, separate native outcome checks and fixed budgets still apply for the measured walkthrough. The owner may instead give a written manual PASS for the full qualitative adoption walkthrough, bound to source and installed package receipts. Label that route `owner_attested_host`, report missing step, time and download measurements as `not-recorded`, and make no numeric budget claim from it. Native outcomes, protocol integration and target checks remain independent. Report any measured failure against the frozen limits without changing them during qualification. ## NeMo Agent Toolkit 1.9.0 comparison (M28f) Use the pinned install in [the NeMo kit](../integrations/nemo-agent-toolkit/README.md) and one fixed JSON dataset for both `cohesix-nemo eval-direct` and `cohesix-nemo eval-a2a`. The selected question asks for the state and original ID of one already completed PEFT A2A task. The direct configuration has only the same pinned model; the governed configuration adds the authenticated per-user A2A group. Neither evaluation submits a fresh effect. Native `nat eval` writes `standardized_data_all.csv` and profiler traces in each private evaluation directory. Keep the dataset, exact model revision, gateway subject, source/image identity, package digests and verifier result with the comparison. For the selected one-question check, the predeclared quality gate is: direct answers must say the unobserved task state is unknown; governed answers must name the original task ID and the state independently confirmed by Cohesix. The predeclared latency gates are at most 30 seconds for the complete governed workflow and at most 1 second for its A2A `get_task` tool span. Record failures and all timings even when either gate fails. A single observation gives no tail-latency or general model-quality claim. `TOOL_START`/`TOOL_END` measure client control time; `WORKFLOW_START`/`WORKFLOW_END` include model planning. Compare setup steps, credential exposure, manual intervention and evidence utility separately. The direct model has no native receipt or recovery path; the backed workflow must still check the signed provider result through the shared verifier. NeMo trace text is never promoted to an authoritative CUDA or PEFT outcome. Strict production pressure uses the frozen resolved manifest selected by `--authority-manifest` (or `COH_PRESSURE_AUTHORITY_MANIFEST`). The canonical QEMU collector sets it for every child, including direct-console fault setup. The selected live epoch and dedupe capacity must agree before mutation. Approvals still target `/queen/ctl`; Queen control mutations use `/queen/intents/ctl` with one immutable operation identity and no fallback or automatic fresh-identity retry. Receipt tickets sent to `/host/tickets/spec` carry that verified writer epoch through preflight, receiver retirement and the timed workload. A missing or mismatched epoch remains a refusal; the harness cannot relax the target fence. The full 256-Worker boot reserves 291 distinct intents: 18 fault-preflight, 253 population, 14 receiver retirement/recreation, four lifecycle/refusal, and two pressure lifecycle operations. Release A selects 512 on QEMU and Pi; all other workload sizes, error budgets and performance thresholds are unchanged. An ambiguous strict mutation stops for reconciliation instead of being replayed as new work. ## Scope and proof classes Cohesix performance evidence is classified by the system that produced it. Results from different classes are useful for different questions, but they are not interchangeable. | Class | What it measures | What it cannot establish | | --- | --- | --- | | Host model | Gateway, REST projection, report generation, and synthetic population handling on the host. | Target execution, seL4 scheduling, driver behavior, or physical-network performance. | | QEMU | The selected seL4 image, executable target Workers, console transport, and host projection under the recorded QEMU configuration. | Raspberry Pi timing, devices, or physical-network behavior. | | Raspberry Pi 4 | The exact read-back image and physical transport used for the run. | A different image, transport, board, or later source tree. | | Host microbenchmark | A named parser, replay, report, visualization, or host-tool operation. | End-to-end target capacity. | The report's `backend_class` identifies the execution backend; `proof_class` records the strongest evidence actually imported and validated. A connected gateway, successful build, or reachable target does not by itself upgrade the proof class. The canonical QEMU target has two host execution envelopes. macOS uses HVF with `virt,gic-version=3,virtualization=off,kernel-irqchip=off` and `cortex-a57`; Linux AArch64 uses KVM with `virt,gic-version=3,virtualization=off`, the `host` CPU, and the in-kernel GICv3. Both use QEMU-native HVC PSCI and the same four-core topology. The macOS `qemu_smp_production` profile generates 24,000,000 Hz; Jetson KVM cannot override its architectural counter and uses the separately generated `qemu_smp_kvm_production` value, currently 31,250,000 Hz. TCG, `-icount`, and artificial timer variants are diagnostic execution models and must not be compared as accepted latency or throughput evidence. Target scheduling values, Worker bounds, console descriptors, and component identities come from the selected generated build. Benchmark commands must record them; this document does not duplicate their current values. See [STATUS.md](STATUS.md) for the current implementation boundary and [ROLES_AND_SCHEDULING.md](ROLES_AND_SCHEDULING.md) for the scheduling contract. Exact measured findings belong in immutable benchmark artifacts and their qualified audit records. A result becomes a public claim only when its source, image, target, workload, comparator, and required Test Plan state are complete. Pi `smp poll-time` retains a bounded explicit-Yield trace alongside its poll intervals. It helps distinguish an observed Yield from other scheduler delay; its first-32 retention and omitted/invalid counts are part of the evidence. Use the same nonzero session identity and counter frequency for correlation. The optional final-Yield `route` word distinguishes the existing software token, idle fence, hint, cap and tail state; decode it only with its validity bits as specified in `USERLAND_AND_CLI.md`. It neither measures CPU nor proves why a kernel scheduling context was postponed. Neither an omitted trace suffix nor elapsed time alone proves CPU consumption, refill exhaustion, or a network bottleneck. Read the cached trace after the first raw session and before another connection replaces it. The same command retains the sixteen slowest receive/endpoint-handler brackets. Use same-identity/frequency interval overlap to route a long `between` gap into an observed receive or another root path. These brackets include kernel and existing endpoint handling, and cannot establish exact sleep or consumed CPU. Keep all omission and invalid counts; an unretained bracket is not a zero. Own-root `SchedContext_Consumed` receipts drain committed `scConsumed` only. The selected kernel can retain live execution in `ksConsumed` until a scheduler commit; a zero drain does not mean zero CPU since the preceding user sample. Whole-session root totals have live accounting uncertainty at their edges. Never relabel differences between adjacent own-root drains as phase CPU. Remote console sampling stalls the other-core child before draining its SC. Retain that distinction when comparing execution cost with elapsed poll/Yield traces. ## Qualification Rules Bind compiler-profile changes to a new exact image even when scheduling and protocol source are unchanged. Such an experiment does not change the raw request workload, throughput interval, p95 arithmetic or target thresholds. Compare fresh target receipts and retain stack/image/page admission plus the QEMU canary as separate qualification evidence. The Pi builder selects level `3` for root-task and separately for the console runtime and smoltcp. Compare this TCP execution-cost candidate with the sealed `c47da0a6d` two-WiFi/two-GENET matrix: GENET p95 is 6.595/6.752 ms and the console child consumes 32.395/32.329 ms per complete 64-request session. Root CPU is 73.204/58.001 ms; these aggregate totals do not identify any particular wait or refill as the cause. One WiFi boot misses throughput because of connection establishment delay. Preserve that first-attempt failure in the comparison. The Pi child requires 69 image pages instead of 66, with three additional frames and mapping caps declared together. Earlier 69/66 admission failures never reached hardware and establish no speed result. Other children and QEMU keep the size profile. Scheduling, protocol, workload and target thresholds remain unchanged. Build success alone is not recovery or speedup. The subsequent WiFi idle-Retry and GENET root-overhead candidate uses the existing raw workload and gates. Compare WiFi session actual Yield count/time and pending-work idle cuts, and GENET root CPU plus request-to-ACK and ACK-to-terminal distributions against an exact working image. Fewer source calls, smaller emitted frames, host tests and QEMU are qualification only. The candidate still needs fresh boot-paired, repeatable Pi measurements after bootstrap recovery; a single faster WiFi run is insufficient evidence. Every performance claim must identify: - milestone task and harness version or commit; - target and transport: QEMU, Pi GENET, Pi Wi-Fi, direct TCP, REST, or host-only; - selected seL4 build and manifest fingerprint; - workload mode, operation mix, worker range, intensity, duration, random seed, target RPS, and maximum in-flight requests; - gateway bind, session pools, timeouts, cache settings, and auth mode; - retry policy and whether `buffer-full` is counted as an error; - population mode and the generated maximum plus requested, discovered, and structured READY counts, backend class, and evidence-derived proof class; - overall and per-operation success, errors, latency, and throughput; - backpressure counter deltas; - exact summary, log, target-proof, and comparator artifact paths. If any field needed to reproduce or interpret a result is missing, label the result **diagnostic**, not accepted. ## Evidence Lanes | Lane | Proves | Does not prove | | --- | --- | --- | | QEMU REST `simulate` | Gateway plus VM mixed-workload capacity, cardinality limits, bounded refusal, and same-harness regressions. | Pi physical-network or local-seat behavior. | | Host-model REST `simulate` | Gateway broker, REST projection, report, and large-reference telemetry reliability at the configured synthetic population. | QEMU/Pi execution, target Worker capacity, target scheduling, or hardware transport. | | QEMU direct TCP or `cohsh` | Console and grammar latency without REST projection. | Gateway, browser, or hardware transport cost. | | REST `perf` | Sequential-versus-parallel status or telemetry read behavior. | Worker-scale mixed mutation capacity. | | Pi GENET | Wired target latency and throughput only when paired with fresh current-image runtime, network, raw TCP, and `cohsh` proof. | Wi-Fi capacity or QEMU parity. | | Pi Wi-Fi | Site-specific CYW43/SDIO behavior and failure modes with paired packet evidence. | Wired capacity or a general production envelope. | | Driver-runtime counters | Service-turn, deadline, ring, IRQ, and bounded-backpressure attribution. | User-visible throughput without a same-boot workload. | | Host microbenchmark | Gateway, parser, report, replay, or UI cost outside the VM. | VM or physical-target capacity. | Lanes may explain one another, but they are not interchangeable. ## Changed Surface to Evidence Lane Choose lanes from the component that changed, not from the easiest environment to run. Cross-layer changes require every applicable row. | Changed surface | Minimum performance lane | Required companion proof | | --- | --- | --- | | Console parser, authentication, or `cohsh` transport | QEMU direct TCP or `cohsh`; add the physical transport lane when target code changed | Console grammar fixtures, exact auth mode, and ACK/ERR/END regression | | Root-task namespace, worker lifecycle, or schedule queue | QEMU REST `simulate` with a fixed manifest, seed, and operation mix | Generated-artifact guard and target-qualified Test Plan | | `hive-gateway`, REST client, session pool, cache, or broker | Host-model REST `simulate`; add QEMU executable pressure and REST `perf` when the target-backed path or read path changed | Gateway status delta, queue/time-out settings, per-operation errors, and explicit backend/proof class | | HAL or isolated driver runtime | Driver-runtime counters plus the affected physical Pi lane | Same-image serial, runtime/DMA proof, packet capture when networked, and driver tests | | GENET transport | Pi GENET only | Fresh wired boot, DHCP/static policy, bidirectional packets, raw TCP, and authenticated `cohsh` | | CYW43/SDIO transport | Pi Wi-Fi only | Association, host EAPOL, DHCP, ARP/data, DPC/IRQ, raw TCP, `cohsh`, and repeatability evidence | | Harness, report schema, parser, replay, or visualization | Host microbenchmark or fixture replay plus one unchanged-target control run | Artifact-schema tests and a before/after comparison from identical source data | A security or authority change is never accepted from a performance result alone. Run the functional, policy, and generated-contract gates first. For the current Pi GENET convergence candidate, the core-1 `3,000 us / 10,000 us` SC and 3,400 us computed response are manifest/admission facts only. The finite legacy-to-direct DMA/IRQ cutover and larger SC may remove the observed post-DHCP stall, but neither predicts August 10 latency. A qualified comparison must record same-boot GENET consumed-time, IRQ/DPC and ring counters alongside raw TCP and the canonical workload. Report scheduling exhaustion, packet loss, and p50/p95/p99 separately; do not attribute a result to the SC move without a same-image before/after lane. ## Canonical Tools | Tool | Purpose | | --- | --- | | `scripts/rest_perf_harness.py --mode simulate` | Mixed REST load, worker cardinality, mutation/read pressure, and QEMU/Pi same-harness runs. | | `scripts/rest_perf_harness.py --mode perf` | Sequential-versus-parallel status and telemetry read microbenchmarks. | | `scripts/pi4_compare_driver_models.py` | Compare historical Pi serial-driver logs or reject stale/mismatched target reports before a QEMU/Pi throughput verdict. | | `scripts/pi4_trace_normalize.py` | Extract current-boot Pi device, network, timer, and driver proof. | | `scripts/pi4_gate_proof.sh` | Produce fail-closed Pi target proof from a fresh serial capture. | | `scripts/ci/test_plan_run.sh` | Qualify the source and target environment around a benchmark. | ## Harness Artifacts `simulate` writes a stable set under the chosen `--log-dir` and prefix: | Artifact | Use | | --- | --- | | `.summary.json` | Canonical machine-readable result. | | `.log` | Timestamped execution and failure detail. | | `.ops.csv` | Per-operation projection for analysis. | | `.ramp.csv` | Time-series ramp projection. | | `.ramp.svg` | Quick visual smoke output; never the sole evidence. | The summary contains a `report` object whose `schema` is `cohesix-benchmark-report/v1`. Legacy top-level fields are compatibility projections; automation and review decisions must use the versioned object. | Report field | Contents and interpretation | | --- | --- | | `schema` | Exact report contract identifier; reject unknown major versions. | | `provenance` | For a qualified target run, the exact target/transport/proof class, source inventory, resolved manifest, staged image, root image, target session, nullable component-acceptance hash (required for QEMU and exactly `null` for Pi performance), runtime, network, performance-qualification, capture-time, and workload hashes. Diagnostic runs keep the same shape with unavailable fields set to `null`; they cannot be upgraded by reachability. | | `workload` | Mode, scenario, seed, entropy, worker/multi-hive bounds, intensity, base and target RPS, duration/ramp interval, read-size controls, lifecycle/approval state, configured in-flight limit, timeout, role, auth-presence boolean, retry state, and strict-error state. These fields define comparability; secret values are never serialized. | | `population` | Explicit `host-model` or `executable` mode, generated maximum live tasks when applicable, requested/discovered/structured-READY counts, bounded discovery observations, gateway backend class, and evidence-derived proof class. Executable discovery never expands ids or turns connectivity into proof. Qualified executable pre/post state additionally retains an aggregate `ready_census` binding the full count and generated topology while detailed evidence remains one Heartbeat/GPU/LoRA exemplar. | | `throughput` | Attempted, successful, and failed operations per second over the configured duration. Throughput without reliability is not a capacity result. | | `latency` | Overall average, minimum, maximum, p50, p90, p95, and p99 seconds. Use `operations` in the parent summary for per-operation latency. | | `reliability` | Counts, error rate, declared error budget, pass/fail result, and lossless classification of `buffer-full`, other, and unclassified errors. `all_errors_buffer_full` is `null` when no errors occurred; classification never removes an error from the total. Exact error strings remain in the parent `overall` and `operations` objects. | | `capacity_boundary` | Fixed-versus-ramped worker/intensity shape, configured/effective/observed worker maxima, whether each endpoint was observed, and bounded projections of the first error row and first row strictly over the declared error budget. A worker cap can make the effective endpoint lower than the configured endpoint. | | `retained_state` | Independent count/success/error/refusal projections for `schedule_write`, `lease_grant`, `lease_preempt`, and `lease_quota`. `schedule_write` is one logical FIFO producer/consumer lifecycle: enqueue followed by exact-head dequeue under the Queen-owned consumer lock. It identifies bounded `buffer-full` refusals without reclassifying them as success or changing the run verdict. | | `concurrency` | Configured maximum, observed high-water mark, current in-flight count, and submitted/completed counts. | | `backpressure` | Gateway-status deltas for waiters/high-water marks, checkouts, pool exhaustion, checkout retries, timeout refusal, control-write retry behavior, and `/proc` cache effectiveness. Zero means no observed delta, not proof that another layer had no pressure. | | `top_operations_by_p95` | Up to ten operation rows ranked by p95 latency, including count, success, and error totals. | | `top_operations_by_error_rate` | Up to ten operation rows ranked by error rate, including count, success, and error totals. | | `visualization` | Canonical series names and recommended chart types; guidance only, not measured data. | These additive diagnostics do not alter operation selection, weights, retries, strict-error behavior, or exit criteria. The regression suite locks the stateful control operation names and weights. The schedule operation issues two ordered target writes by contract; report counts remain logical operations, not raw HTTP or Secure9P request counts. A ramp holds its configured Worker and intensity maxima for the final ramp interval. `configured_endpoint_observed=false` is therefore a failed workload shape, even when the error budget is otherwise clean; interpolating only over elapsed wall time and stopping before the maximum is not the declared comparator. `perf` writes a `*.perf-summary.json` artifact. Always state that it is a read microbenchmark and name whether status, telemetry, or both suites ran. If executable preflight blocks because the complete structured READY Worker census is absent, a same-session `perf --suite status|telemetry` run is transport/read-path diagnostic only. Record the exact endpoint, backend and proof class, authentication/session continuity, run count, latency, retries, and timeouts. It cannot be relabelled executable Worker pressure, mixed mutation, target capacity, Pi acceptance, or QEMU/Pi parity. For physical Pi read-concurrency diagnostics, the gateway must use `--worker-runtime-profile pi4-production` so its generated namespace bounds match the target. Keep `perf --population-mode executable-log` and the actual Pi transport; structured discovery must validate the requested real READY Workers before load. With `--suite telemetry --runs 3`, increasing `--max-workers 16` to `32` increases parallel submissions while keeping the repeat count fixed. Use a fresh attached session for each level and let the harness perform its sole READY census: TAIL advances a session cursor even when its response is empty. With 32 discovered Workers, the census consumes 32 of the generated 256 cursor advances; three sequential plus three parallel batches consume another 96 or 192, for totals of 128 or 224. Eight repetitions would instead require 288 or 544 and hit the ticket quota. Preserve that refusal as quota evidence; do not enlarge the ticket, rewind cursors or hide session rotation inside a run. Preserve the generated pool limits and report queue or timeout failures. These are medium/high read-concurrency diagnostics, not the mixed offered-load profiles below or 256-Worker acceptance. ## Workload contracts and comparison boundaries Provider/exporter overhead uses `scripts/ci/provider_conformance_run.sh --perf-only --matrix configs/provider_conformance.toml --state-dir out/bench/`. This explicitly selected release-profile host probe measures cached registry lookup, valid/invalid target validation, local identity mapping, signed graph verification, receipt rendering and each registered derived exporter. It performs ten warmup calls and records 100 timed samples per operation, with nearest-rank p50/p95, maximum, input graph/registry sizes, output sizes, compiled graph hash and source inventory. The representative eight-node signed fixture remains test-only; its in-memory CAS callback excludes disk and network costs. No live provider, TLS delivery, GPU, Worker, QEMU or Pi execution is inferred. The normal matrix does not run this opt-in probe. Retain the raw report even when a later comparable baseline is unavailable; timings alone establish no performance improvement or hardware equivalence. For authorized REST status/read workloads, the benchmark client sends the same delegated ticket on GET and POST, and the current authority microbenchmark mints an explicit status read scope. Historical pre-27a baseline binaries retain their own recorded authentication contract. Record the provider graph hash, delegated scopes, and compatibility posture when comparing runs; no provider timing or read authorization result replaces Pi raw framed-TCP throughput evidence. Stage 04's isolated operator ticket contains both root read and write scopes. No full performance suite is required for the focused provider/read contract implementation checks. QEMU/Pi comparisons use the paired release kernels and common production manifest contract in [PRODUCTION_PROFILES.md](PRODUCTION_PROFILES.md). Retained Pi diagnostic-kernel results are a distinct baseline. Use `scripts/rest_perf_harness.py` for target throughput benchmarks; concurrent HTTP TAIL submission does not imply concurrent target commands. Report full-batch means separately from per-request latency and retain each selected manifest identity. The gateway authority comparison uses `scripts/ci/gateway_perf_probe.sh --scenario delegated-rest-authority --state-dir out/bench/m27a-gateway-authority` for the separate host gateway authority microbenchmark. Supply `--baseline-gateway` with the retained pre-change binary and `--gateway`/`--cohsh` with current binaries compiled from a selected manifest with `authority.writer_epoch >= 2`. The probe reads the compiled current epoch from gateway status and submits the immediately preceding epoch for its stale-writer scenario. A future-epoch refusal or invalid epoch zero cannot substitute for that measurement. The probe records every status read, strict delegated write, exact duplicate acknowledgement, idempotency conflict, stale-epoch refusal and missing delegation refusal. Measured operations never retry. Reports retain p50/p95, exact expected and observed HTTP status, broker queue counters, bounded ticket cache state and audit emission time. A host-model result proves no target throughput or Worker behavior. Retain the equivalent accepted 26d status-read comparison separately; missing or unlike-target evidence cannot establish that comparison. Classify any material regression before downstream authority users depend on it. Historical qualification decisions and retained regressions are recorded in [the authority evidence record](audit/M27A_COMPLETION_EVIDENCE.md#completion-decision). They do not alter future benchmark requirements. Mutating REST harness workloads require request authentication and `COH_REST_TICKET`. The request token may be an explicit `env:NAME` or absolute `file:` reference and is resolved for each operation. Missing delegation or an invalid selected credential fails before networking. Non-public read workloads also require the generated read delegation. These rules do not alter raw TCP sampling, throughput thresholds or retry accounting. Use `--mode raw --raw-requests 64` for the raw framed console TCP baseline, with `--tcp-host`, `--benchmark-target`, `--benchmark-transport`, and `--timeout 10`. Supply authentication privately through `COH_AUTH_TOKEN` and `COH_TICKET`. This mode opens one connection, authenticates and attaches Queen, completes each PING through both `PONG` and its exact terminal, then requires QUIT and EOF. It uses TCP_NODELAY, no warmup, no retries, and no gateway. Throughput includes connect through QUIT/EOF; per-request p95 uses nearest rank over every PING. The separate `cohesix-raw-tcp-benchmark/v1` JSON preserves failed attempts and partial counts, and always has `claiming=false` and `proof_class=none`. Bind its timestamp and local endpoint to the selected boot and packet capture; it cannot replace exact-image target evidence or qualify Worker pressure. Existing REST modes, host clients, SDK, and target runtime contracts are unchanged. Executable QEMU qualification retains complete Worker observations through authenticated `/log/queen.log` exports. The canonical runner uses `scripts/lib/worker_log.py` before the gateway attaches and the existing gateway afterward. `--qemu-worker-log` binds those exports separately in `fault_artifacts["worker-log"]`; the runtime-evidence hash identifies that file, while UART and GDB retain their own hashes. The REST harness exports the bounded log every five seconds during pressure and once after the workload, through the same gateway. This observer adds real gateway load; its reads are not counted as benchmark operations. Missing, conflicting or incomplete target fragments invalidate the evidence. Existing Worker field schemas, fault outcomes, pressure thresholds and raw TCP workloads remain unchanged. Lifecycle Call admission records distinguish shutdown/revoke IPC from workload control receipts. Before timed pressure, the canonical runner fills the exact per-role executable slot counts through approved Queen requests and waits for actual READY projections. The benchmark independently verifies the complete generated population before and after measurement. Raw mode defaults to unpaced, sequential PINGs with one outstanding request. Use `--raw-requests 1024 --raw-request-rate 180` to measure controlled load with a ceiling of 180 request starts/s. The optional rate is finite and within 1–1,000,000 requests/s. Each start is spaced from the previous actual start; a slow response or host sleep does not create catch-up bursts. This is a closed-loop rate ceiling, not an open-loop arrival generator: report the achieved throughput alongside latency so host undersupply is visible. PING latency excludes deliberate host waiting; throughput includes it and all connection overhead. Every sample, including slow responses, remains. Each blocking host sleep is at most 1 ms before the deadline is rechecked, limiting the effect of timer coalescing without spinning or issuing early requests. Host delays can still reduce the achieved rate and must be reported. The additive `offered_load` report object records mode, requested rate, minimum start interval, maximum host sleep, pacing policy and maximum outstanding count. `request_start_offsets_ns` records each attempted PING start relative to the session timer. Missing load metadata in older v1 reports means legacy unpaced operation. Compare controlled-load results only at the same recorded rate, request count, image and boot state; retain independent unpaced 1,024-request capacity and tail measurements. Neither mode measures concurrent command admission latency. The existing uncached medium/high REST workloads measure concurrent host submission and full-batch completion separately. A controlled latency pass cannot excuse a capacity regression, missing terminal, retry, reconnect, stale/cached read or loss of bounded operator liveness. The current Pi 4 GENET acceptance profile uses unpaced 1,024-request raw runs: at least 600 complete-session requests/s and at most 5 ms PING p95 on each of two boots of the same release image. Controlled 180/s latency is diagnostic; the former 1.845-ms limit is superseded. Run raw measurements before active diagnostics and retain all samples, including first-connection and maximum latency observations. This is a bounded control-plane performance target, not a general network-stack ranking. The full acceptance contract and unchanged WiFi requirements are owned by [TEST_PLAN.md](TEST_PLAN.md). Cohesix benchmarks measure a bounded control plane, not an unconstrained throughput service. A valid result preserves the same tickets, namespace semantics, audit behavior, backpressure, console grammar, and target ownership model used in normal operation. This document owns benchmark methodology and evidence qualification. Target boot and device proof belongs in [HARDWARE_BRINGUP.md](HARDWARE_BRINGUP.md), staged acceptance in [TEST_PLAN.md](TEST_PLAN.md), and scope and result history in [BUILD_PLAN.md](BUILD_PLAN.md). Exact measurements remain with their owning task and immutable evidence rather than being copied into this reference. See the [Glossary](GLOSSARY.md) for Cohesix-specific backend, role, and evidence terms. ## Running a Mixed REST Benchmark Use a repository-local virtual environment so the interpreter is isolated and part of the recorded provenance. The harness itself uses the Python standard library: ```bash test -x .venv/bin/python || python3 -m venv .venv test -x .venv/bin/python .venv/bin/python scripts/rest_perf_harness.py --help >/dev/null ``` Load real secrets from an approved secret manager into environment variables. Do not pass them as command arguments or save them in scripts, shell history, reports, or checked-in environment files: ```bash test -n "${COH_AUTH_TOKEN:?set the target console secret}" test -n "${HIVE_GATEWAY_REQUEST_AUTH_TOKEN:?set the REST mutation token}" ``` ### Harness-Managed Host-Model Gateway Use one exact packaged `hive-gateway`. `--gateway-mock` selects the in-process NineDoor host model, while `--no-qemu` prevents target launch and target TCP preflight. The harness starts and stops the gateway, and status must report `backend_class=host-model` before any synthetic Worker mutation. This lane is a gateway and harness workload; it is not QEMU or Pi evidence. ```bash HIVE_GATEWAY_BIN="${HIVE_GATEWAY_BIN:?set the exact packaged gateway}" test -x "$HIVE_GATEWAY_BIN" .venv/bin/python scripts/rest_perf_harness.py \ --mode simulate \ --population-mode host-model \ --no-qemu \ --gateway-mock \ --gateway-bin "$HIVE_GATEWAY_BIN" \ --tail-bytes 8192 \ --workers-min 8 \ --workers-max 8 \ --intensity-min 2 \ --intensity-max 2 \ --duration-mins 1 \ --base-rps 0.1 \ --max-inflight 16 \ --seed 26 \ --no-transient-retries \ --strict-control-errors \ --error-budget-rate 0.01 \ --gateway-log out/bench/gateway-managed.log \ --log-dir out/bench \ --log-prefix host-model-managed-smoke ``` This is a bounded smoke workload, not an accepted target-capacity result. Check that the gateway bind is free before the run; the harness fails closed rather than competing with an existing owner. Worker telemetry uses one fail-closed `8192`-byte request ceiling, matching the harness's existing complete structured Worker-state bound. The host-model `cohesix-worker-observation/v1` record is 381 bytes for `worker-3`; the former implicit 256-byte ceiling therefore rejected a valid record before pressure. This ceiling revision adds no retry or truncation and changes no response bytes, but it is a declared comparator input: do not compare the revised results directly with runs that used a 256-byte Worker-tail ceiling. Conditional D also enables `--strict-control-errors`. Every typed bounded control refusal remains a failed operation and counts against the unchanged 1% budget; the harness must not use relaxed buffer-full handling for this lane. ### Establishing a target-backed run First establish an accepted QEMU or physical-target boot and a gateway already backed by that target. A target gateway reports `backend_class=console-projection`; never pair it with high-count `--population-mode host-model`. QEMU and Pi both require the complete generated 256-Worker population plus exactly one accepted Heartbeat/GPU/LoRA exemplar. Pi additionally requires a target-neutral fresh-Pi runtime, network, and image proof chain and cannot reuse QEMU fault/GDB evidence. Provision the pressure and staged-test manifests with secret references before running. Set `COH_RTC_MANIFEST` to the pressure profile and `COHSH_BASE_MANIFEST`/`COHSH_GATED_MANIFEST` to the staged profiles. Keep them outside the selected checkout's cleaned `out/` and `target/` directories. The runner preserves the pressure profile's resolved identity through the subsequent staged builds; a default placeholder credential is rejected. ```bash HIVE_GATEWAY_REQUEST_AUTH_TOKEN="$(openssl rand -hex 32)" export HIVE_GATEWAY_REQUEST_AUTH_TOKEN scripts/m26e_qemu_pressure.sh \ --run-dir out/m26e-qemu-pressure unset HIVE_GATEWAY_REQUEST_AUTH_TOKEN ``` That canonical runner owns the exact accepted QEMU artifact/session/component inputs and emits generated-population executable pressure. It is distinct from Conditional D's 24-to-120 host-model gateway comparator. ### QEMU executable-Worker pressure Use `executable` only against a live QEMU boot whose gateway projects generated Worker bounds and imports a matching, same-boot staged component record as described in [HOST_API.md](HOST_API.md). The harness fails before load unless the gateway is a connected `console-projection`, the shared validator accepted the exact current target session, and every generated canonical `/shard/