diff --git a/.gitignore b/.gitignore
index deb9c338..0b4e84b0 100644
--- a/.gitignore
+++ b/.gitignore
@@ -75,10 +75,11 @@ Testing/
src/native/third_party/**/build/
_deps/
-# NOTE: assets/native/PresentMon.exe is deliberately NOT ignored. 12_BUILD.md
-# calls it "bundled ... pinned, SHA-256 verified at build"; whether it is
-# committed or fetched is an open question (docs/20_OPEN_QUESTIONS.md).
-# Ignoring it here would silently prevent committing it.
+# NOTE: there are no bundled native assets. assets/native/PresentMon.exe was the
+# only one ever planned and PresentMon was DROPPED on 2026-08-27 (S31 row P2,
+# then an owner decision). The path is left unignored anyway: if a future Tier-2
+# mechanism ever needs a bundled binary there, an ignore rule is how it would be
+# missed rather than reviewed.
# /presentmon/ IS ignored, and it is NOT the path above. A hand-downloaded copy
# of the Intel console binary landed at the repository root on 2026-08-27 --
diff --git a/CHANGELOG.md b/CHANGELOG.md
index d376536e..36b1e0c9 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -19,6 +19,43 @@ GitHub release body, so a missing section will mean an empty release note.
### Changed
+- **PresentMon is DROPPED — owner decision 2026-08-27 — and Tier 2 keeps its place while losing
+ its mechanism.** §S31 retired it as a measurement oracle (row P2); this removes it as an
+ implementation. It is not bundled, not fetched, not used, and `tools/frametype-oracle.ps1` — the
+ parser written for its output — is deleted with it, along with its `build.ps1` gate.
+
+ **Twelve documents named it as the Tier-2 mechanism and every one is corrected**: `CLAUDE.md`'s
+ pinned-stack row, `README`'s capture-tier table **and its safety row**, `01_ARCHITECTURE`'s tier
+ table and ADR-3, `03_METRICS` rung 2, `04_CAPTURE`'s source table and tier selection,
+ `05_DETECTION`'s two Tier-2 rows, `07_IPC`'s `PresentMonMissing` error code, `12_BUILD`,
+ `13_CI_CD`, `14_TESTING`'s CSV-parser row, `15_ROADMAP`'s P2 phase and v2 backlog, and
+ `legal/THIRD_PARTY_NOTICES.md` plus `legal/licenses/README.md`.
+
+ **The notices row and `license-check`'s claim had to go together, and that is the gate working.**
+ `tools/license-check.ps1` bound `Intel PresentMon` to `assets/native/PresentMon.exe`
+ bidirectionally; removing the row alone fails with *"no table row mentions Intel PresentMon, so
+ its bundling claim cannot be checked"*. Removing a claim is a deliberate act and is recorded as
+ one. `legal/licenses/README.md` also listed a `presentmon-MIT.txt` that never existed.
+
+ **§M1, §M2 and §M6 close by DECISION, not by measurement**, and each says so: they were questions
+ about a tool that no longer has a subject. §M2's answers are kept in full because every one cost a
+ measurement. **§G is not closed — it gets bigger**: *"is the binary committed or fetched?"* becomes
+ *"by what mechanism does a shipped build reach Tier 2 at all?"*, and nothing in this repository
+ names one.
+
+ **What this costs users, stated where they will read it.** `README`'s **safety** row promises a
+ no-injection mode as *"always a way out"*, and `legal/DISCLAIMER.md` §73 and `legal/EULA.md` §33
+ both call it **the default** for uncertain cases. The README row now carries the fact that it is
+ unbuilt and has no chosen mechanism, so **a refused or unhookable title gets Tier 3** — session
+ duration and hardware telemetry. The two legal documents still say "default" without that
+ qualification; §G owns the gap and names them. Not fixed here, because changing a legal document
+ is not a cleanup.
+
+ **And the discriminator run was attempted and produced nothing**, so it settled nothing: the
+ command targeted `explorer.exe`, which may present nothing PresentMon tracks, and "no CSV" is
+ indistinguishable from "no `FrameType` column" — the §Traps entry about a canary that dies before
+ reaching the gate. Badly chosen target, recorded as such, and moot now.
+
- **§S31 ran, and PresentMon is RETIRED as the application-frame oracle — row P2.**
Three legs, three game launches, Cyberpunk 2077 at off / ×2 / ×4. `FrameType` is present and
**every row of all three legs reads `Application`** — 1,937 / 6,488 / 10,881 rows, no other
diff --git a/CLAUDE.md b/CLAUDE.md
index f9ef5a75..8b23b38a 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -35,7 +35,7 @@ A C++ DLL (`FrameLedger.Overlay.dll`) is injected into games the user explicitly
| Charts | ScottPlot 5 |
| GPU telemetry | Layered: DXGI + PDH counters (all vendors) → LibreHardwareMonitorLib (MPL-2.0, all vendors) → **NVAPI (MIT, headers + `amd64/nvapi64.lib` vendored 2026-08-05** at `src/native/third_party/nvapi/`, consumed via the `fl_nvapi` target; NVIDIA extras + Reflex). **No AMD/Intel vendor SDK** — `docs/18_GPU_VENDOR_APIS.md`. **No telemetry source exists in code yet** — `ctest fl_nvapi_probe` is the only consumer, and it exists so the vendoring is verified rather than asserted. This row previously claimed the vendoring in the present tense while `third_party/` held only `vulkan-headers`; `legal/` had already caught the identical claim about itself and gained a bidirectional gate, which is what made the real vendoring a red-then-green |
| CPU/board sensors | LibreHardwareMonitorLib ≥ 0.9.6 (PawnIO) — **optional**, elevated only |
-| Tier-2 fallback | Intel PresentMon console binary (ETW) |
+| Tier-2 fallback | **Undecided.** ETW-based, no injection — the mechanism is an open question (`docs/20_OPEN_QUESTIONS.md` §G). ~~Intel PresentMon console binary~~ dropped by owner decision 2026-08-27 after §S31 retired it as an oracle; nothing in this repository names a Tier-2 tool |
| Storage | SQLite via Microsoft.Data.Sqlite + Dapper (no EF) |
| Shared memory IPC | `CreateFileMapping` + lock-free SPSC ring — `docs/07_IPC.md` |
| Logging | Serilog (managed); ring-buffer + deferred flush (native) |
@@ -81,8 +81,9 @@ tests/
FrameLedger.CaptureHost.Tests/ # incl. the Category=Integration end-to-end case
native/FrameLedger.Overlay.Tests/ # Catch2: ring buffer, record encode, fault policy
tools/ # changelog-check, chokepoint-check, coverage-gate, gen-ac-floor,
- # license-check, package-closure-check, rules-validate,
- # vendor-exports, versioninfo-check, vklayer-blastradius
+ # hookinventory-check, license-check, package-closure-check,
+ # rules-validate, vendor-exports, versioninfo-check,
+ # vklayer-blastradius
# (PowerShell). This line used to name three, one of which
# — resx-audit — does not exist.
# native tooling lives under src/native/tools:
diff --git a/README.md b/README.md
index 2f6a979b..7947a49b 100644
--- a/README.md
+++ b/README.md
@@ -55,7 +55,7 @@ FrameLedger is built to keep that risk small and to be honest about it:
| **Hard refusal** | Known anti-cheat/anti-tamper components are detected before injection and every 30 s during a session. Detected ⇒ FrameLedger refuses, or stops capturing at the next scan — so up to 30 s can pass before it reacts to anti-cheat that loads mid-session. For Direct3D/OpenGL that means hooks are removed; for Vulkan it means the layer goes passthrough, because a layer cannot leave the loader chain of a running game. **There is no override — not in settings, not in a config file, not on the command line**
⚠ **Half of this is built.** The *pre-injection* refusal is real and runs every documented check. The **in-session re-scan does not run at all**: the component inside the game removes its hooks within one frame of being told to, and within 65 s if it stops hearing from the scanner — but nothing yet drives the scanner during a session, so nothing ever tells it. `legal/DISCLAIMER.md` §2 states this in full. The Vulkan layer additionally intercepts nothing yet, so there is no Vulkan capture to stop. |
| **No evasion, ever** | FrameLedger does not hide, rename, obfuscate, or disguise itself. It keeps its real name, real exports, and version info. It is meant to be plainly visible to any security software that looks. This is an architectural rule, not a setting |
| **Read-only** | It never reads or writes game memory, never modifies game behavior, never touches saves or input, and never changes GPU clocks, fans, or power limits |
-| **Always a way out** | A no-injection mode (ETW-based) is the default for anything the software is unsure about. It needs the Agent running elevated, because Windows restricts the trace sessions it uses — FrameLedger tells you when that applies rather than silently recording less |
+| **Always a way out** | A no-injection mode (ETW-based) is the default for anything the software is unsure about. It needs the Agent running elevated, because Windows restricts the trace sessions it uses — FrameLedger tells you when that applies rather than silently recording less
⚠ **None of this is built, and as of 2026-08-27 it does not even have a chosen mechanism.** The design named Intel PresentMon; that was dropped after measurement, and no replacement has been picked (`docs/20_OPEN_QUESTIONS.md` §G). **Today a refused or unhookable title gets Tier 3** — session duration and hardware telemetry — not a degraded measurement. Said here rather than in a footnote, because this row is in the SAFETY table and a way out that does not exist is the wrong thing to be reassured by |
**FrameLedger is for offline and single-player games.** If you enable it for anything with an online or competitive component, that is your call and your responsibility. The developer cannot reverse a ban. Please read [`legal/DISCLAIMER.md`](legal/DISCLAIMER.md) and [`docs/19_SAFETY_AND_ANTICHEAT.md`](docs/19_SAFETY_AND_ANTICHEAT.md) before enabling it for anything.
@@ -64,7 +64,7 @@ FrameLedger is built to keep that risk small and to be honest about it:
| Tier | How | What you get |
|---|---|---|
| **1** | Injected hooks (opt-in, per game) | Everything above |
-| **2** | ETW / Intel PresentMon, no injection (**needs an elevated Agent**) | Frame times, FPS, lows, present mode, coarse frame-generation inference |
+| **2** | ETW, no injection — **mechanism not chosen, nothing built** | Frame times, FPS, lows, present mode. *(An earlier design named Intel PresentMon and promised coarse frame-generation inference. PresentMon was dropped on 2026-08-27 after its `FrameType` column classified every frame of a ×4 capture as an application frame; there is no Tier-2 frame-generation signal today and none is claimed.)* |
| **3** | None | Session duration + hardware telemetry |
The tier is recorded on every session and shown in the UI. Metrics unavailable at a session's tier read `N/A` — FrameLedger never substitutes an estimate for a measurement.
diff --git a/build.ps1 b/build.ps1
index d6a26168..ab985a0b 100644
--- a/build.ps1
+++ b/build.ps1
@@ -414,21 +414,6 @@ function Invoke-ProjectGates {
Skip-Gate 'changelog-check' 'tools/changelog-check.ps1 not implemented yet'
}
- # THE ONLY THING STANDING BEHIND AN UNVALIDATED PARSER. tools/frametype-oracle.ps1
- # has never been fed a real PresentMon CSV -- the console binary will not start a
- # trace session on the dev box without elevation (spike-notes §11) -- so its column
- # set and FrameType vocabulary are assumptions. Its decision table is what makes
- # the assumptions FAIL LOUDLY instead of quietly, and a table nobody runs is a
- # comment. Self-test only: there is no CSV to check in the gate.
- Write-Step 'frametype-oracle'
- $oracleTool = Join-Path $repo 'tools/frametype-oracle.ps1'
- if (Test-Path $oracleTool) {
- Invoke-Checked 'frametype-oracle (self-test)' { & $oracleTool -SelfTest }
- }
- else {
- Skip-Gate 'frametype-oracle' 'tools/frametype-oracle.ps1 not implemented yet'
- }
-
Write-Step 'resx-audit'
$resxTool = Join-Path $repo 'tools/resx-audit'
if (Test-Path $resxTool) {
diff --git a/docs/01_ARCHITECTURE.md b/docs/01_ARCHITECTURE.md
index 14324ec2..700954f3 100644
--- a/docs/01_ARCHITECTURE.md
+++ b/docs/01_ARCHITECTURE.md
@@ -46,7 +46,7 @@
| Tier | Mechanism | Gets you | When used |
|---|---|---|---|
| **1** | Injected hooks (default when the user enabled it and the guard passed) | Everything: exact render/output res, upscaler + quality, FG ground truth, RT/PT evidence, per-process VRAM, PSO stutter attribution, Reflex latency, present flags | Offline/single-player titles the user opted in |
-| **2** | ETW via PresentMon console (no injection) | Frame times, present mode, displayed vs presented counts, coarse FG inference | Guard refused, hook failed, user chose not to hook, or cross-checking Tier 1 |
+| **2** | ETW, no injection — ~~via PresentMon console~~ **mechanism undecided** (§G) | Frame times, present mode, displayed vs presented counts. ~~coarse FG inference~~ — that came from PresentMon's `FrameType`, which §S31 retired for NVIDIA, so no Tier-2 FG signal is claimed | Guard refused, hook failed, user chose not to hook, or cross-checking Tier 1 |
| **3** | Nothing | Session duration + sensors only | Capture disabled |
Tier is recorded per session (`sessions.capture_tier`) and shown in the UI, because metric availability differs and comparing across tiers must be explicit.
@@ -109,7 +109,7 @@ covers\*.jpg
- **ADR-1 (superseded):** ~~Passive ETW only; injection out of scope.~~ Replaced by ADR-7.
- **ADR-2:** WPF over WinUI 3 — Velopack maturity, ecosystem stability, portfolio reuse.
-- **ADR-3 (revised):** ETW/PresentMon is now the **Tier-2 fallback**, not the primary source. The `IFrameSource` abstraction that made this cheap to change is retained and vindicated.
+- **ADR-3 (revised twice):** ETW is the **Tier-2 fallback**, not the primary source. ~~ETW/PresentMon~~ — the **tool** is no longer named: §S31 retired PresentMon's `FrameType` as an oracle on 2026-08-20–27 and the owner dropped it on 2026-08-27, so Tier 2 has a tier and no implementation. The `IFrameSource` abstraction that made this cheap to change is retained and **vindicated a second time**: the mechanism changed underneath it and no consumer moved.
- **ADR-4:** Raw frame series stored as compressed blobs with retention; aggregates kept forever.
- **ADR-5 (revised):** In-game overlay is now *possible* (we are already in the process) and is planned as an opt-in feature after the data path is stable — see `15_ROADMAP` P5.
- **ADR-6:** UI toolkit = WPF UI (lepoco `Wpf.Ui` ≥ 4.3.0, MIT) — see `16_WPFUI_SYNTAX.md`.
diff --git a/docs/03_METRICS.md b/docs/03_METRICS.md
index 59539f67..1a8914eb 100644
--- a/docs/03_METRICS.md
+++ b/docs/03_METRICS.md
@@ -86,7 +86,8 @@ This is the metric the rewrite exists for. Resolution ladder, highest confidence
> whole ladder exists to prevent, reached from a new direction.
>
> §S31 carries the pre-committed decision table, including the two rows that retire
-> the rung outright. `tools/frametype-oracle.ps1` is what produces the input, and
+> the rung outright. `tools/frametype-oracle.ps1` **was** what produced the input
+> — deleted 2026-08-27 with the tool it parsed — and
> also the reason `spike-notes` §11 now records that the console binary will not run
> unelevated on the dev box at all.
>
diff --git a/docs/04_CAPTURE.md b/docs/04_CAPTURE.md
index f1707b02..540e0933 100644
--- a/docs/04_CAPTURE.md
+++ b/docs/04_CAPTURE.md
@@ -15,14 +15,14 @@ public interface IFrameSource : IAsyncDisposable
| Implementation | Tier | Notes |
|---|---|---|
| `HookedFrameSource` | 1 | Injects (or relies on the Vulkan layer), maps the ring, drains at 10 Hz |
-| `EtwFrameSource` | 2 | ~~Bundled~~ PresentMon console binary, CSV over stdout — unchanged from the previous design, now a fallback. **Not bundled** (owner decision 2026-08-27): the console binary is a local test tool, and how a shipped build reaches Tier 2 is undecided — `20_OPEN_QUESTIONS` §G. `EtwFrameSource` is unwritten either way, so nothing depends on this today |
+| `EtwFrameSource` | 2 | **No mechanism.** ~~Bundled PresentMon console binary, CSV over stdout~~ — PresentMon was dropped on 2026-08-27 (§S31 row P2, then an owner decision) and nothing replaced it. This row names a PORT WITH NO ADAPTER: `EtwFrameSource` is unwritten, and what it would read is `20_OPEN_QUESTIONS` §G. Do not plan P2 as though writing it were scoped |
| `MockFrameSource` | dev | Synthetic frames incl. simulated FG/upscaler/RT records; `FL_MOCK=1` |
Tier selection per launch:
```
hookingEnabledForGame && guardPasses && injectionSucceeds → Tier 1
-otherwise, if the Agent is elevated (ETW needs it) → Tier 2
+otherwise, if the Agent is elevated (ETW needs it) → Tier 2 [no implementation — §G]
otherwise → Tier 3 (duration + sensors only)
```
diff --git a/docs/05_DETECTION.md b/docs/05_DETECTION.md
index 3f84b54e..76790938 100644
--- a/docs/05_DETECTION.md
+++ b/docs/05_DETECTION.md
@@ -20,7 +20,7 @@ Derived in the Agent from the record stream; the mapping is in `03_METRICS`. Sum
| HDR output | `SetColorSpace1` |
| Upscaler identity + quality preset | NGX / Streamline / FFX / XeSS create+evaluate calls |
| Render resolution vs output resolution (incl. mid-session changes) | upscaler parameter reads + `ResizeBuffers` |
-| Frame Generation mode + factor | NGX/SL/FFX FG feature evaluation, then (Tier 2 only) PresentMon `FrameType`, then cadence |
+| Frame Generation mode + factor | NGX/SL/FFX FG feature evaluation, ~~then (Tier 2 only) PresentMon `FrameType`,~~ then cadence — the `FrameType` rung is retired (§S31 row P2) and Tier 2 has no tool |
| Ray Tracing active | AS builds + `DispatchRays` (both, to catch inline RayQuery) |
| Ray Reconstruction | NGX `RayReconstruction` feature evaluated |
| Reflex on + PC latency | NVAPI Reflex hooks |
@@ -37,7 +37,7 @@ Derived in the Agent from the record stream; the mapping is in `03_METRICS`. Sum
> stale-by-not-being-touched failure this project keeps recording; `06_DATA_MODEL`'s
> `fg_source` enum carried the same value and is corrected in the same pass.
-Tier-2 sessions have `upscaler = unknown`, resolutions `N/A`, RT `N/A`, and an FG mode only if PresentMon's `FrameType` or cadence resolves it.
+Tier-2 sessions have `upscaler = unknown`, resolutions `N/A`, RT `N/A`, and an FG mode only if ~~PresentMon's `FrameType` or~~ cadence resolves it — **cadence is the only rung Tier 2 has left**, and it yields `Detected (unknown)` at best, never a named technology.
## Static hints — rules engine
diff --git a/docs/07_IPC.md b/docs/07_IPC.md
index 80488a2c..0634183e 100644
--- a/docs/07_IPC.md
+++ b/docs/07_IPC.md
@@ -286,7 +286,7 @@ Unchanged in spirit from v1, bumped to `v2` for the new message set.
| `CaptureRefused` | A→UI | `{ gameId, reason, signal }` — **guard fired**; UI shows the plain-language explanation and the Tier-2 offer |
| `CaptureDegraded` | A→UI | `{ sessionGuid, from, to, reason }` — Tier 1 → Tier 2 mid-flight, or overlay self-disabled |
| `SafetyUnhook` | A→UI | `{ sessionGuid, signal }` — anti-cheat appeared mid-session; prominent UI notice |
-| `CaptureError` | A→UI | `{ code, message }` — `InjectFailed`, `RingVersionMismatch`, `EtwAccessDenied`, `PresentMonMissing`, `TelemetryUnavailable`, `DbWriteFailed` |
+| `CaptureError` | A→UI | `{ code, message }` — `InjectFailed`, `RingVersionMismatch`, `EtwAccessDenied`, ~~`PresentMonMissing`~~ (retired with the tool, 2026-08-27 — a code naming an implementation nobody chose), `TelemetryUnavailable`, `DbWriteFailed` |
| `Ping`/`Pong` | both | 15 s keepalive |
## The pipe is not a trust boundary
diff --git a/docs/12_BUILD.md b/docs/12_BUILD.md
index 9f0adf63..06145443 100644
--- a/docs/12_BUILD.md
+++ b/docs/12_BUILD.md
@@ -89,7 +89,7 @@ Agent flags: `--serve`, `--console`, `--diag`, `--install-task`, `--uninstall-ta
## Bundled assets
-- ~~`assets/native/PresentMon.exe` (pinned, SHA-256 verified at build) for the Tier-2 fallback~~ — **RETIRED BY OWNER DECISION, 2026-08-27: the console binary is a LOCAL TEST TOOL and is not bundled.** It stays on the developer's machine for the §S31 measurement and for `tools/frametype-oracle.ps1`'s input; the release will reach Tier 2 by a different route, and **which route has not been decided** (`20_OPEN_QUESTIONS` §G). Two consequences worth stating rather than discovering: there is now **no shipping mechanism for Tier 2 at all** — `15_ROADMAP` parks PresentMon Service + API2 in **v2**, and §M2 already recorded that there is no planned fallback if the console is gone — and `README`, `legal/DISCLAIMER.md` and `legal/EULA.md` all describe a Tier 2 that users can reach. Whatever replaces it has to satisfy those three documents or they have to change.
+- ~~`assets/native/PresentMon.exe` (pinned, SHA-256 verified at build) for the Tier-2 fallback~~ — **DROPPED 2026-08-27, and there are no bundled native assets at all.** §S31 measured PresentMon classifying every frame of a ×4 capture as an application frame (row P2); the owner then dropped it outright. It is not bundled, not fetched, not used, and `tools/frametype-oracle.ps1` — the parser that consumed its output — is deleted with it. `assets/` does not exist and now has no reason to. **Tier 2 keeps its place in the design and has no mechanism**: `EtwFrameSource` is unwritten and what it would read is `20_OPEN_QUESTIONS` §G.
The struck text is kept because the *reason* it was written is still live. What it said next, and what remains true:
diff --git a/docs/14_TESTING.md b/docs/14_TESTING.md
index 3c94cf98..542b0f9a 100644
--- a/docs/14_TESTING.md
+++ b/docs/14_TESTING.md
@@ -37,7 +37,7 @@ The anti-cheat guard is the one component where a bug can cost someone an accoun
### Parsers & infrastructure
- Shm reader against a synthetic mapping: version mismatch → refuse; torn records skipped; dropped counter propagated.
-- PresentMon CSV (Tier 2): header-map building with shuffled/unknown/missing columns, malformed lines, invariant decimal. Fixtures recorded from real runs.
+- ~~PresentMon CSV (Tier 2): header-map building with shuffled/unknown/missing columns, malformed lines, invariant decimal. Fixtures recorded from real runs.~~ **Removed 2026-08-27 with the tool.** Whatever Tier 2 ends up parsing needs its own row, written against the format it actually reads — and the lesson from the one parser that did get written is worth carrying: its CSV's first column was named `Application` while the value it counted was also `Application`, so resolving by NAME rather than position was load-bearing (`spike-notes` §11).
- Steam ACF (KeyValues), GOG `.info`, Epic `.item`, itch receipt — real-world fixtures.
- `RuleEvaluator`: fixture directory trees per engine, including the "Unity markers present but UE structure too" ordering case.
- Blob codecs round-trip for every series in `frame_blobs` (NaN forbidden — assert), including the two-pair `render_res` encoding and the three-bit `rt_flags` byte. SQLite migrations apply cleanly from an empty file to the current schema, and re-applying is a no-op. (There is no v1→v2 upgrade to test — `06_DATA_MODEL` §Migrations.)
diff --git a/docs/15_ROADMAP.md b/docs/15_ROADMAP.md
index 27dbe953..ec15dde0 100644
--- a/docs/15_ROADMAP.md
+++ b/docs/15_ROADMAP.md
@@ -285,7 +285,7 @@ Findings written to `docs/spike-notes.md`. Nothing in P1 starts until the exit c
> re-scan wired to a real Overlay.
## P2 — Capture pipeline (1 week)
-Agent: watcher, tier selection, injection orchestration, shm drain, telemetry poller (NVAPI first), session recorder, segments, `.partial` recovery, Tier-2 `EtwFrameSource` retained as fallback. SQLite v2 schema + migrations. Domain metric calculators + golden tests. **Milestone: first real hooked session persisted with measured upscaler/RT data.**
+Agent: watcher, tier selection, injection orchestration, shm drain, telemetry poller (NVAPI first), session recorder, segments, `.partial` recovery, ~~Tier-2 `EtwFrameSource` retained as fallback.~~ **There is nothing to retain: Tier 2 has no mechanism as of 2026-08-27** (§G). `EtwFrameSource` is a port with no adapter, and P2 should not be planned as though writing one were scoped. SQLite v2 schema + migrations. Domain metric calculators + golden tests. **Milestone: first real hooked session persisted with measured upscaler/RT data.**
## P3 — UI (1 week)
WPF UI shell (`16_WPFUI_SYNTAX`), library, per-game hooking consent flow, Dashboard live card showing *measured* settings, session summary, ScottPlot charts, game detail tabs, Compare with tier guarding, segment ribbon, tri-state chips with override, refusal/degradation/unhook notices as first-class UI.
@@ -307,7 +307,7 @@ CI/CD with the native build; CodeQL (C# + C++); Dependabot; CHANGELOG; README wi
## v2 backlog
-- PresentMon Service + API2 for a richer Tier 2
+- ~~PresentMon Service + API2 for a richer Tier 2~~ — **struck 2026-08-27**: PresentMon is dropped, so this cannot be the *richer* version of something that is not the baseline any more. What v2 may want is a Tier-2 mechanism at all; **v1 does not have one** (§G)
- **YouTube overlay export**: frametime/FPS graph as transparent PNG sequence for DaVinci Resolve benchmark videos (SkullMute workflow)
- CapFrameX-compatible CSV import/export
- Microsoft Store / Game Pass titles (packaged-app injection constraints)
diff --git a/docs/20_OPEN_QUESTIONS.md b/docs/20_OPEN_QUESTIONS.md
index f750c092..58252e8b 100644
--- a/docs/20_OPEN_QUESTIONS.md
+++ b/docs/20_OPEN_QUESTIONS.md
@@ -28,7 +28,7 @@ Rules for this document:
| — | **D3D9 is not a Tier-1 API in v1.** The Overlay is x64-only; an x64 DLL cannot load into a 32-bit process, and D3D9 titles are almost entirely 32-bit | The VN / JRPG / older-indie catalogue is Tier 2. Reversing this means a second 32-bit Overlay **and** injector, doubling the native build matrix and adding a second struct-mirror surface. Revisit only with evidence that users care more about those titles than about the maintenance cost |
| — | **`ci.yml` is repo-local**, not a caller stub | The ops repo's `reusable-desktop-csharp.yml` runs `dotnet` directly with no native pre-step input, and `12_BUILD` requires CI and local to run the same script |
| — | **No `v1 → v2` migration** | Nothing shipped, so no such database exists. `0001_init.sql` creates the current schema |
-| — | **Tier 2 requires an elevated Agent** | An unelevated Agent whose Tier-1 attempt fails lands on Tier 3. Stated in the README, Disclaimer and EULA |
+| — | **Tier 2 requires an elevated Agent** | An unelevated Agent whose Tier-1 attempt fails lands on Tier 3. Stated in the README, Disclaimer and EULA. **Still true and now vacuous, 2026-08-27:** the requirement comes from Windows restricting ETW trace sessions, not from any tool, so it survives PresentMon being dropped — but there is no Tier-2 implementation for it to apply to (§G) |
---
@@ -844,7 +844,20 @@ a wrong answer into a confident wrong answer.
> re-reading. **It still needs elevation, so it is the owner's** — attempted unelevated
> 2026-08-27 and refused with the same exit 6 this item has been blocked on from the start.
>
-> **THE ACTION DOES NOT DEPEND ON IT, WHICH IS WHY THIS ROW LANDS ANYWAY.** Both branches end
+> > **AND THE DISCRIMINATOR WAS RUN, AND PRODUCED NOTHING — 2026-08-27.** The owner ran it
+> > from an elevated shell and no CSV appeared anywhere: not at the given path, not in either
+> > TEMP, not in the repository. **That is not an answer, and it must not be read as one.**
+> > The command named `explorer.exe` as the target, and a process that presents nothing through
+> > a swapchain PresentMon tracks produces no file — so "no CSV" and "no `FrameType` column"
+> > are indistinguishable here, which is the §Traps entry *"a canary that dies before reaching
+> > the gate looks exactly like a canary that worked"*. The command was badly chosen; a target
+> > known to present (`hook-harness --hold-presenting`) would have settled it.
+> >
+> > **It is now moot.** PresentMon was dropped outright on 2026-08-27, so the reason this
+> > sub-question would have decided — whether a later attempt with a different invocation was
+> > worth anyone's time — no longer has anything to decide about. Recorded rather than deleted
+> > so nobody re-runs it believing it is untried.
+>> **THE ACTION DOES NOT DEPEND ON IT, WHICH IS WHY THIS ROW LANDS ANYWAY.** Both branches end
> at the same place: either the vendor emits nothing, or the invocation produced no frame-type
> data at all. In both, PresentMon did not answer the question **as invoked**, and an oracle
> that does not answer is retired rather than re-run until it does — the discipline
@@ -909,7 +922,7 @@ and divides by nothing.
> Recorded here rather than discovered mid-run, because the previous oracle's output
> *read like confirmation* and was not.
-**What produces the input.** `tools/frametype-oracle.ps1`, run against a PresentMon
+**What produced the input** *(past tense: the tool was deleted on 2026-08-27 with PresentMon; kept here because the reasoning is why the run could be trusted).* `tools/frametype-oracle.ps1`, run against a PresentMon
2.x CSV and, optionally, a saved CaptureHost report. It compares **two dimensionless
ratios** — PresentMon's `displayed / application` against our `presents / batch` —
which is §S30's own correction applied: comparing *rates* needs a shared span, and
@@ -3237,10 +3250,10 @@ instead, which needs no thread at all.
| # | Question |
|---|---|
-| M1 | Can PresentMon 2.x `FrameType` see **driver-level** frame generation (AMD AFMF)? `03_METRICS` now says v1 cannot detect it at Tier 1. If Tier 2 can, that is a genuine and surprising capability inversion worth surfacing in the UI |
-| M2 | ◐ **Partly measured 2026-08-20** (`spike-notes` §11). It exists — PresentMon **2.5.1**, 956,768 bytes, SHA256 `9BEC…A191` — and it carries **no VERSIONINFO at all**, so pinning means pinning the hash and the filename. It does **NOT** run unelevated on this machine: exit 6, *"requires either administrative privileges or to be run by a user in the Performance Log Users user group"*, and the account is neither. The 2.x column set is therefore still **unmeasured**, which is why `tools/frametype-oracle.ps1` resolves columns by name and refuses loudly. **✅ The column set is MEASURED 2026-08-27: 24 columns, listed in `spike-notes` §11, and the parser has now eaten three real CSVs.** It resolved `FrameType` correctly against a first column literally named `Application`, a collision that would have made a position-based or grep-based parser count process names. What stays open in this row is the elevation-free route, not the column set. `15_ROADMAP` parks the Service + API2 in v2, so there is no planned fallback if the console is gone |
+| M1 ✅ | ~~Can PresentMon 2.x `FrameType` see **driver-level** frame generation (AMD AFMF)?~~ | **Closed by DECISION 2026-08-27, not by measurement, and the distinction matters.** PresentMon is dropped, so this question has no subject. What was learned before it went: `FrameType` reports events a vendor chose to emit, and NVIDIA's DLSS-G emits none (§S31 row P2) — so the "capability inversion" this row hoped for was never demonstrated for any vendor. If a Tier-2 mechanism is ever chosen (§G), ask this of **that** tool rather than reviving this row |
+| M2 ✅ | ~~Does the pinned console binary still exist, run unelevated, and emit the 2.x column set?~~ | **Answered, then closed 2026-08-27.** It exists (2.5.1, 956,768 bytes, SHA256 `9BEC…A191`, **no VERSIONINFO at all**); it does **not** run unelevated (exit 6 — the account is in neither Administrators nor Performance Log Users, and the running `PresentMonSharedService` does not help because the console starts its own session); and the 2.x column set **is measured** — 24 columns, `spike-notes` §11. The parser ate three real CSVs and resolved `FrameType` correctly against a first column literally named `Application`. Closed because the binary is dropped, and kept in full because every one of those facts cost a measurement |
| M5 | **Do LHM GPU sensors work unelevated, without PawnIO?** This decides whether the default unelevated Agent has temperatures at all, and therefore how ADR-9 reads to users |
-| M6 | ◐ **Half of it is answered, 2026-08-20, and it is the half nobody expected to fall.** *"or the PresentMon Service"* — **no.** `PresentMonSharedService` is installed and `Running` as LocalSystem on this machine, and the console binary still fails with access denied, because the console starts its **own** trace session rather than talking to the service. So the service being present is not a route to elevation-free Tier 2 for the console. The *"add me to Performance Log Users"* half stays open: adding an account to a local group is a system settings change needing admin, and it is the owner's rather than a session's. Would change the README, Disclaimer and EULA wording back |
+| M6 ✅ | ~~Elevation-free Tier 2~~ | **Closed by decision 2026-08-27.** Half was answered on 2026-08-20 in the direction nobody expected: `PresentMonSharedService` is installed and `Running` as LocalSystem and the console **still** fails, because it starts its own trace session. The other half — whether `Performance Log Users` suffices without admin — stays unmeasured and now has no subject. **The elevation question does not disappear with the tool**: ETW trace sessions are restricted by Windows, not by PresentMon, so whatever §G chooses inherits it. Re-ask it there |
| M7 | `18_GPU_VENDOR_APIS` §Runtime policy says telemetry is never read from the game process, but `17_HOOK_ENGINE` reads per-process VRAM and Reflex latency there. Reconcile the wording — the rule means "no vendor SDK polling loops in the game", not "no measurement in the game" |
| M8 | The `GpuSample` type has no latency field, yet L3 is credited with Reflex/PC latency. Latency is per-frame and arrives via the ring, not the 1 Hz sample. Fix the layering description |
| M9 ✅ | **Closed 2026-08-02 by a decision.** The old file/module detection does not exist in this repository and the owner confirmed there is no copy elsewhere, so **"build a minimal static-hint detector as the measurement baseline" is now P0 item 3** (`15_ROADMAP`). It needs no guard and no injection. Until it exists, ADR-7's headline claim stays out of the README rather than being asserted unmeasured |
@@ -3264,7 +3277,7 @@ Each of these is referenced by an existing doc but specified nowhere.
| **Accessibility / DPI** | NFR-9 states requirements; no design anywhere | NFR-9, `08_UI` |
| **Uninstall / data deletion** | One Velopack clause. No in-app "delete all my data", despite the privacy position | `12_BUILD`, `legal/PRIVACY_POLICY.md` |
| **Cover art** | Appears in the schema, the data directory and the UI; nothing says where it comes from or the licence position on downloaded store art | `06_DATA_MODEL`, `05_DETECTION` |
-| **PresentMon distribution** | ~~`12_BUILD` says "bundled … pinned, SHA-256 verified at build" — is the binary committed to the repo or fetched at build time?~~ **ANSWERED 2026-08-27 (owner): NEITHER. The console binary is a LOCAL TEST TOOL** — it stays on the developer's machine for the §S31 run and as `tools/frametype-oracle.ps1`'s input, it is not committed, not fetched, and not redistributed. `/presentmon/` is ignored; `assets/native/PresentMon.exe` is not created. `12_BUILD`, `13_CI_CD`, `04_CAPTURE` and `legal/THIRD_PARTY_NOTICES.md` all asserted the bundling plan and are corrected in the same PR. **A DIFFERENT QUESTION IS NOW OPEN IN ITS PLACE, and it is bigger: how does a SHIPPED build reach Tier 2 at all?** `15_ROADMAP` parks PresentMon Service + API2 in **v2**; §M2 already recorded that there is no planned fallback if the console is gone; and `README`, `legal/DISCLAIMER.md` and `legal/EULA.md` all describe a Tier 2 users can reach. So retiring the bundle does not close this row — it moves it from a packaging question to a **capability** one, and the three user-facing documents are the constraint on whatever answers it | `12_BUILD`, `THIRD_PARTY_NOTICES`, `README`, `15_ROADMAP` |
+| **Tier-2 mechanism** *(was: PresentMon distribution)* | ~~is the binary committed to the repo or fetched at build time?~~ **Dead question: PresentMon is dropped entirely, 2026-08-27** — not committed, not fetched, not used. **What replaces it is bigger, and is now the only live Tier-2 question: by what mechanism does a shipped build reach Tier 2 at all?** Nothing in this repository names one. Constraints on any answer: `README`'s capture-tier table and its **safety** row *"always a way out"*, plus `legal/DISCLAIMER.md` §73 and `legal/EULA.md` §33, all describe a no-injection mode as **the default** for uncertain cases — the README now carries the fact that it is unbuilt, the two legal documents do not and that is a gap this row owns; ETW needs elevation regardless of tool (§M6); and `15_ROADMAP` has no v2 fallback either any more. **Until this is answered, a refused or unhookable title gets Tier 3** | `README`, `legal/DISCLAIMER.md`, `legal/EULA.md`, `04_CAPTURE`, `15_ROADMAP` |
---
diff --git a/docs/HANDOFF.md b/docs/HANDOFF.md
index 5414fc79..c4c2d544 100644
--- a/docs/HANDOFF.md
+++ b/docs/HANDOFF.md
@@ -437,8 +437,8 @@ arithmetic, the refusals and the fixtures are in and gated. What is missing is n
> said three oracles had fallen; a file whose whole subject is staleness contradicted itself
> inside one entry, which is recorded rather than quietly repaired.
>
-> ~~**And the owner's list for the §S31 run**~~ — **RUN 2026-08-27. `tools/s31-capture.ps1`
-> drove it, three legs, three game launches, and it landed on row **P2**: `FrameType` present
+> ~~**And the owner's list for the §S31 run**~~ — **RUN 2026-08-27.** A runbook script drove it
+> — three legs, three game launches — and it landed on row **P2**: `FrameType` present
> and **every row of all three legs `Application`**, while the two instruments agreed on the
> present rate to within 0.3% — so PresentMon saw the generated presents and classified none
> of them as generated.
diff --git a/docs/spike-notes.md b/docs/spike-notes.md
index 28660408..5152aa8c 100644
--- a/docs/spike-notes.md
+++ b/docs/spike-notes.md
@@ -1673,7 +1673,9 @@ into a real title and the process survives it (§7).
### 🔴 THE RUN HAPPENED — 2026-08-27, three legs, three game launches, and row **P2**
-Owner-run from an elevated shell via `tools/s31-capture.ps1`. Cyberpunk 2077, frame
+Owner-run from an elevated shell via a three-leg runbook script. **That script is not in
+this repository** — it drove PresentMon, so it was closed unmerged when PresentMon was dropped
+the same day; do not go looking for it. Cyberpunk 2077, frame
generation off / ×2 / ×4 set in the title's own menu, 40 s per leg, one game launch
each. Analysis is in `20_OPEN_QUESTIONS` §S31; what belongs here is what was measured.
@@ -1725,6 +1727,11 @@ unelevated 2026-08-27 and refused with the same exit 6 this section opens with.
> vendor emitted nothing, or the invocation produced no frame-type data at all. In
> neither case did PresentMon answer the question **as invoked**.
+**The discriminator was run on 2026-08-27 and produced no file at all**, so it settled nothing:
+the command targeted `explorer.exe`, which may present nothing PresentMon tracks, and "no CSV"
+is indistinguishable from "no `FrameType` column". Badly chosen target, recorded as such. Moot
+now — PresentMon was dropped the same day — and written down so nobody re-runs it thinking it
+is untried.
**Two findings nobody was looking for.**
- **The `off` leg drained ZERO Streamline batches**, against `presents/batch = 1.000`
diff --git a/legal/THIRD_PARTY_NOTICES.md b/legal/THIRD_PARTY_NOTICES.md
index c51aca5e..6ff620a6 100644
--- a/legal/THIRD_PARTY_NOTICES.md
+++ b/legal/THIRD_PARTY_NOTICES.md
@@ -29,7 +29,7 @@ FrameLedger is licensed under **GPL-3.0-only**. It includes or depends on the th
| Component | Use | License | Notes |
|---|---|---|---|
| **MinHook** | Inline function hooking in `FrameLedger.Overlay` | BSD-2-Clause | Vendored and built from source, pinned by commit. Copyright notice must ship in `legal/licenses/` |
-| Intel PresentMon (console binary) | Tier-2 fallback frame timing (ETW) | MIT | **Not yet bundled, and no longer planned to be** — owner decision 2026-08-27: it is a **local test tool**, kept on the developer's machine, and the release will reach Tier 2 by a route nobody has chosen yet (`docs/20_OPEN_QUESTIONS.md` §G). `assets/` does not exist in this repository, nothing is redistributed, and the Tier-2 source is unimplemented. This row stays because the decision can be revisited and a licence obligation that appears the day it is would otherwise appear unannounced. © Intel Corporation |
+*(The **Intel PresentMon** row was removed on 2026-08-27. It is not bundled, not fetched, not redistributed and no longer used at all — §S31 retired it as a measurement oracle and the owner then dropped it outright — so a notice for it would be over-disclosure, which this document treats as a defect in the same way an omission is. `tools/license-check.ps1`'s matching claim was removed in the same commit, because a bidirectional check whose subject no longer exists cannot go green honestly: it would be asserting agreement about nothing.)*
| Vulkan headers / loader interfaces | `FrameLedger.VkLayer` implicit layer | Apache-2.0 | Khronos headers; layer implemented against the documented loader–layer interface |
| LibreHardwareMonitorLib | GPU sensors (all vendors) + CPU/motherboard sensors (optional, elevated) | MPL-2.0 | See §GPU telemetry below. Consumed unmodified |
| WPF UI (`Wpf.Ui`, lepoco) | Fluent UI theme/controls/navigation | MIT | © lepo.co, Leszek Pomianowski and contributors. License copy must ship with the app (MIT requirement) |
@@ -89,7 +89,7 @@ All product names, logos, and brands are property of their respective owners and
- [ ] `legal/licenses/` contains full texts: MIT (per-project copies, **including `nvapi-MIT.txt`**), BSD-2-Clause (MinHook), MPL-2.0, Apache-2.0
- [ ] About → Third-party tab lists this table with versions filled from `Directory.Packages.props`
-- [ ] PresentMon license + copyright shipped beside the bundled binary — **not applicable while it is not bundled** (owner decision 2026-08-27). Left unticked rather than deleted: it becomes applicable again the moment any Tier-2 route redistributes an Intel binary, and a deleted checklist item is one nobody re-derives
+- ~~PresentMon license + copyright shipped beside the bundled binary~~ — **removed 2026-08-27 with the dependency.** Nothing Intel-authored is distributed by this project
- [ ] MPL-2.0 source-availability note points to upstream LibreHardwareMonitor repository
- [x] LHM checked for MPL-2.0 Exhibit B on any depended-upon file — clear as of 0.9.6 / commit `3d331e33`, 2026-08-02
- [x] **NVAPI is vendored** (2026-08-05) and all nine headers carry their `SPDX-License-Identifier: MIT` blocks unmodified — asserted file by file, not sampled. `license-check.ps1` enforces that this line and the table agree with the filesystem, **in both directions**: vendoring the material while the table still said "Not yet" failed the build, which is how this row came to be flipped
diff --git a/legal/licenses/README.md b/legal/licenses/README.md
index cf895bd1..960cb319 100644
--- a/legal/licenses/README.md
+++ b/legal/licenses/README.md
@@ -12,7 +12,6 @@ Required before the first release
| `minhook-BSD-2-Clause.txt` | MinHook — vendored and built from source |
| `nvapi-MIT.txt` | NVIDIA NVAPI SDK — headers + import library vendored |
| `wpfui-MIT.txt` | WPF UI (lepoco) — MIT requires the notice to ship |
-| `presentmon-MIT.txt` | Intel PresentMon — ships beside the bundled binary |
| `librehardwaremonitor-MPL-2.0.txt` | LibreHardwareMonitorLib, consumed unmodified |
| `apache-2.0.txt` | Serilog, Dapper, the analyzers, Vulkan headers |
| `mit.txt` | Shared text for the MIT-licensed NuGet packages |
diff --git a/tools/frametype-oracle.ps1 b/tools/frametype-oracle.ps1
deleted file mode 100644
index 0de60437..00000000
--- a/tools/frametype-oracle.ps1
+++ /dev/null
@@ -1,341 +0,0 @@
-#Requires -Version 7.0
-<#
-.SYNOPSIS
- Compares PresentMon 2.x's FrameType classification against FrameLedger's
- presents-per-batch proxy, as two DIMENSIONLESS RATIOS.
-
-.DESCRIPTION
- HANDOFF item 3 rests on a premise nothing in this repository has verified: that
- a drained Streamline batch IS an application frame. Three oracles have already
- been tried and all three fell (20_OPEN_QUESTIONS S30) -- fl-baseline-probe by
- its own written falsifier, and two readings of an in-process present overlay.
- PresentMon 2.x's FrameType column was pre-committed as the next measurement
- because it classifies each present from ETW and divides by nothing.
-
- RATIOS, NOT RATES, and that is the correction S30 records rather than a style
- choice. Comparing rates needs a shared span, the span is where the previous
- draft went circular, and each ratio here is internal to one instrument:
- PresentMon's `displayed / application` against our `presents / batch`. Neither
- side needs to know when the other started.
-
- WHAT THIS SCRIPT HAS NEVER SEEN, stated first because it is the largest
- weakness. No real PresentMon CSV has ever been fed to it. On the machine it
- was written on, PresentMon 2.5.1 refuses to start a trace session at all --
- exit 6, "PresentMon requires either administrative privileges or to be run by
- a user in the Performance Log Users user group" -- so the 2.x column set and
- the FrameType vocabulary are UNMEASURED (spike-notes.md S11). Everything below
- is therefore written to fail LOUDLY on anything it does not recognise rather
- than to guess:
-
- - Columns are resolved BY NAME from the header, never by position.
- - A missing FrameType column is a refusal that prints the columns it did
- find. 03_METRICS S13 already specifies exactly this: "reports an explicit
- capability loss when FrameType is absent rather than silently reporting
- fg_mode = none".
- - The FrameType VOCABULARY is not assumed. The script prints every distinct
- value it saw, and counts as application frames only the rows spelled
- `Application`. If nothing is spelled that way it refuses instead of
- dividing by zero -- a wrong spelling must not become a wrong number.
- - It does NOT implement RFC-4180 quoting. A quoted comma would misalign the
- split, the FrameType column would not be found by name, and the script
- would refuse. That is the safe direction and it is why the name lookup
- happens after the split rather than before.
-
- AND THE FALSIFIER, WRITTEN BEFORE THE RUN. `--track_frame_type` is a BETA
- option in 2.5.1 and its own help says it "requires application and/or driver
- instrumentation using Intel-PresentMon provider". So it is not a general
- classification of any present: it depends on the vendor emitting events. If a
- DLSS-G capture comes back with no FrameType column, or with every row spelled
- `Application` while frame generation was demonstrably on, then PresentMon is
- NOT an application-frame oracle for NVIDIA frame generation and must be
- retired in the same S31 row rather than quietly relied on -- exactly as
- fl-baseline-probe was. This script reports that case as a RETIREMENT and never
- as a ratio of 1.0.
-
-.PARAMETER Csv
- Path to a PresentMon 2.x CSV (`--output_file`, `--v2_metrics
- --track_frame_type`).
-
-.PARAMETER Report
- Optional. Path to a saved FrameLedger.CaptureHost report. The script reads the
- `presents/batch=` figure out of it so the two ratios can be printed together.
-
-.PARAMETER SelfTest
- Runs the decision table below in BOTH directions and exits non-zero if any
- case comes out wrong. build.ps1 runs this on every check, so the one thing
- standing behind an unvalidated parser is itself proven able to go red.
-#>
-[CmdletBinding(DefaultParameterSetName = 'Compare')]
-param(
- [Parameter(ParameterSetName = 'Compare', Mandatory = $true)]
- [string]$Csv,
-
- [Parameter(ParameterSetName = 'Compare')]
- [string]$Report,
-
- [Parameter(ParameterSetName = 'SelfTest', Mandatory = $true)]
- [switch]$SelfTest
-)
-
-Set-StrictMode -Version Latest
-$ErrorActionPreference = 'Stop'
-
-# The column the whole comparison rests on, and the one value that means "the
-# application produced this frame". Named once so the self-test and the live path
-# cannot disagree about the spelling under test.
-$script:FrameTypeColumn = 'FrameType'
-$script:ApplicationValue = 'Application'
-
-<#
- Turns CSV text into a census, or into the reason there is none.
-
- Deliberately NOT a boolean and never a bare number: "no FrameType column",
- "no rows at all" and "every row is an application frame" are three different
- findings, and only the last is a measurement. Collapsing them is how a
- capability loss becomes a factor of 1.0.
-#>
-function New-Census {
- # ONE SHAPE FOR BOTH OUTCOMES. Set-StrictMode turns a missing key into a
- # terminating error, so a refusal that omitted the numeric fields would make
- # every caller's `$c.Refusal` test throw before it could read the refusal --
- # a check that dies before reaching the thing it checks, which is the shape
- # gates-that-cannot-fail is about.
- #
- # $Refusal IS DELIBERATELY UNTYPED. Declaring it [string] makes PowerShell
- # coerce $null to the empty string, so `$null -eq $c.Refusal` is false on a
- # SUCCESSFUL census and every caller reads a success as a refusal. Measured
- # here, not reasoned about: the four success cases in the table below went red
- # while every refusal case stayed green, which is the signature.
- param(
- $Refusal = $null,
- [int]$Total = 0,
- [int]$Application = 0,
- [AllowNull()]$ByType = $null
- )
- return @{
- Refusal = $Refusal
- Total = $Total
- Application = $Application
- Generated = $Total - $Application
- ByType = $(if ($null -eq $ByType) { [ordered]@{} } else { $ByType })
- Ratio = $(if ($Application -gt 0) { $Total / $Application } else { $null })
- AllApplication = ($Application -gt 0 -and $Application -eq $Total)
- }
-}
-
-function Get-FrameTypeCensus {
- param([AllowNull()][string[]]$Lines)
-
- $rows = @()
- if ($null -ne $Lines) {
- $rows = @($Lines | Where-Object { $_ -ne $null -and $_.Trim() -ne '' })
- }
-
- # FAIL-CLOSED ON EMPTY. No header is not "a clean capture"; it means the
- # caller's file is not what they think it is.
- if ($rows.Count -eq 0) {
- return New-Census -Refusal 'the CSV is empty — PresentMon wrote no header, so nothing was captured'
- }
-
- $header = @($rows[0].Split(',') | ForEach-Object { $_.Trim().Trim('"') })
- $index = -1
- for ($i = 0; $i -lt $header.Count; $i++) {
- if ($header[$i] -ieq $script:FrameTypeColumn) { $index = $i; break }
- }
-
- if ($index -lt 0) {
- return New-Census -Refusal ("no '$($script:FrameTypeColumn)' column — this is a CAPABILITY LOSS, not a " +
- "measurement. --track_frame_type is a beta option and needs vendor instrumentation of the " +
- "Intel-PresentMon provider. Columns present: $($header -join ', ')")
- }
-
- if ($rows.Count -lt 2) {
- return New-Census -Refusal 'the CSV has a header and no rows — no present was recorded'
- }
-
- $byType = [ordered]@{}
- $total = 0
- foreach ($line in $rows[1..($rows.Count - 1)]) {
- $fields = @($line.Split(','))
- if ($fields.Count -le $index) { continue }
- $value = $fields[$index].Trim().Trim('"')
- if ($value -eq '') { $value = '' }
- if (-not $byType.Contains($value)) { $byType[$value] = 0 }
- $byType[$value] = [int]$byType[$value] + 1
- $total++
- }
-
- if ($total -eq 0) {
- return New-Census -Refusal 'every row was shorter than the FrameType column — the split did not line up'
- }
-
- $application = 0
- foreach ($key in $byType.Keys) {
- if ($key -ieq $script:ApplicationValue) { $application += [int]$byType[$key] }
- }
-
- # A WRONG SPELLING MUST NOT BECOME A WRONG NUMBER. The vocabulary is
- # unmeasured, so a zero here means "we do not recognise what this build emits"
- # far more likely than "this title produced no application frames".
- if ($application -eq 0) {
- return New-Census -Refusal ("no row is spelled '$($script:ApplicationValue)', so the denominator would " +
- "be zero. The values this capture actually contains are: $($byType.Keys -join ', ')") -ByType $byType
- }
-
- # AllApplication is THE FALSIFIER, carried as a flag rather than as a ratio of 1.0.
- return New-Census -Total $total -Application $application -ByType $byType
-}
-
-<#
- Pulls `presents/batch=N` out of a CaptureHost report. Returns $null when the
- report does not carry one, which is a real state: the host prints it only when
- a batch was drained.
-#>
-function Get-PresentsPerBatch {
- param([AllowNull()][string]$Text)
- if ([string]::IsNullOrWhiteSpace($Text)) { return $null }
- $m = [regex]::Match($Text, 'presents/batch=\s*([0-9]+(?:\.[0-9]+)?)')
- if (-not $m.Success) { return $null }
- return [double]$m.Groups[1].Value
-}
-
-# --- Self-test ---------------------------------------------------------------
-
-function Invoke-SelfTest {
- $cases = @(
- @{ Name = 'a FrameType column with generated frames yields the ratio'
- Lines = @('SwapChain,FrameType,MsBetweenPresents',
- 'a,Application,1', 'a,Repeated,1', 'a,Application,1', 'a,Repeated,1')
- Expect = { param($r) $null -eq $r.Refusal -and $r.Total -eq 4 -and $r.Application -eq 2 -and
- [math]::Abs($r.Ratio - 2.0) -lt 1e-9 -and -not $r.AllApplication } }
-
- @{ Name = 'the column is found BY NAME wherever it sits'
- Lines = @('MsBetweenPresents,SwapChain,FrameType',
- '1,a,Application', '1,a,Repeated', '1,a,Repeated', '1,a,Repeated')
- Expect = { param($r) $null -eq $r.Refusal -and [math]::Abs($r.Ratio - 4.0) -lt 1e-9 } }
-
- @{ Name = 'an UNKNOWN generated spelling still counts as generated'
- Lines = @('FrameType', 'Application', 'Intel XEFG', 'Intel XEFG', 'AMD AFMF')
- Expect = { param($r) $null -eq $r.Refusal -and [math]::Abs($r.Ratio - 4.0) -lt 1e-9 -and
- $r.ByType.Contains('Intel XEFG') } }
-
- @{ Name = 'NO FrameType column is a refusal that names the columns it saw'
- Lines = @('SwapChain,MsBetweenPresents', 'a,1', 'a,1')
- Expect = { param($r) $r.Refusal -match 'CAPABILITY LOSS' -and $r.Refusal -match 'SwapChain' } }
-
- @{ Name = 'every row Application fires the FALSIFIER rather than reporting 1.0'
- Lines = @('FrameType', 'Application', 'Application', 'Application')
- Expect = { param($r) $null -eq $r.Refusal -and $r.AllApplication -and $r.Generated -eq 0 } }
-
- @{ Name = 'a vocabulary with no Application refuses instead of dividing by zero'
- Lines = @('FrameType', 'Repeated', 'Repeated')
- Expect = { param($r) $r.Refusal -match 'denominator would be zero' -and $r.Refusal -match 'Repeated' } }
-
- @{ Name = 'a header with no rows is a refusal, not a clean capture'
- Lines = @('SwapChain,FrameType')
- Expect = { param($r) $r.Refusal -match 'no rows' } }
-
- @{ Name = 'an EMPTY file fails closed'
- Lines = @()
- Expect = { param($r) $r.Refusal -match 'empty' } }
-
- @{ Name = 'a null input fails closed too'
- Lines = $null
- Expect = { param($r) $r.Refusal -match 'empty' } }
- )
-
- $failed = 0
- foreach ($c in $cases) {
- $result = Get-FrameTypeCensus -Lines $c.Lines
- $ok = & $c.Expect $result
- Write-Host (" {0} {1}" -f $(if ($ok) { 'ok ' } else { 'FAIL' }), $c.Name)
- if (-not $ok) { $failed++ }
- }
-
- # The report side, both directions.
- $reportCases = @(
- @{ Name = 'presents/batch is read out of a report line'
- Text = ' FG counts: presents=100 batches=25 span=1.2s presents/batch=4 evaluations/batch=N/A'
- Expect = { param($v) $null -ne $v -and [math]::Abs($v - 4.0) -lt 1e-9 } }
- @{ Name = 'a report WITHOUT one yields null rather than a default'
- Text = ' FG counts: presents=100 batches=0'
- Expect = { param($v) $null -eq $v } }
- @{ Name = 'an empty report yields null'
- Text = ''
- Expect = { param($v) $null -eq $v } }
- )
- foreach ($c in $reportCases) {
- $value = Get-PresentsPerBatch -Text $c.Text
- $ok = & $c.Expect $value
- Write-Host (" {0} {1}" -f $(if ($ok) { 'ok ' } else { 'FAIL' }), $c.Name)
- if (-not $ok) { $failed++ }
- }
-
- $count = $cases.Count + $reportCases.Count
- if ($failed -gt 0) {
- Write-Host "frametype-oracle self-test: $failed of $count case(s) FAILED" -ForegroundColor Red
- exit 1
- }
- Write-Host "frametype-oracle self-test: $count cases, both directions"
- exit 0
-}
-
-if ($SelfTest) { Invoke-SelfTest }
-
-# --- Live comparison ---------------------------------------------------------
-
-if (-not (Test-Path -LiteralPath $Csv)) {
- Write-Host "FAILED: no such CSV: $Csv" -ForegroundColor Red
- exit 2
-}
-
-$census = Get-FrameTypeCensus -Lines (Get-Content -LiteralPath $Csv)
-
-Write-Host ''
-Write-Host "PresentMon CSV: $Csv"
-
-if ($null -ne $census.Refusal) {
- Write-Host " NOT AN ORACLE: $($census.Refusal)" -ForegroundColor Yellow
- Write-Host ' Record this in 20_OPEN_QUESTIONS S31 as a retirement, in the same row, rather than'
- Write-Host ' re-running until it answers. That is what fl-baseline-probe earned.'
- exit 3
-}
-
-Write-Host " frames classified : $($census.Total)"
-foreach ($key in $census.ByType.Keys) {
- Write-Host (" {0,-24} {1}" -f $key, $census.ByType[$key])
-}
-Write-Host " displayed / application = $([math]::Round($census.Ratio, 4))"
-
-if ($census.AllApplication) {
- Write-Host ''
- Write-Host ' FALSIFIER FIRED: every classified frame is an application frame.' -ForegroundColor Yellow
- Write-Host ' If frame generation was demonstrably ON for this capture, PresentMon did not see it,'
- Write-Host ' and it is NOT an application-frame oracle for this vendor. --track_frame_type is a beta'
- Write-Host ' option that needs the vendor to instrument the Intel-PresentMon provider. Retire it in'
- Write-Host ' S31 rather than reading 1.0 as a measurement.'
- exit 4
-}
-
-if ($PSBoundParameters.ContainsKey('Report')) {
- if (-not (Test-Path -LiteralPath $Report)) {
- Write-Host "FAILED: no such report: $Report" -ForegroundColor Red
- exit 2
- }
- $ours = Get-PresentsPerBatch -Text (Get-Content -LiteralPath $Report -Raw)
- Write-Host ''
- Write-Host "FrameLedger report: $Report"
- if ($null -eq $ours) {
- Write-Host ' the report carries no presents/batch — nothing to compare against' -ForegroundColor Yellow
- exit 5
- }
- Write-Host " presents / batch = $ours"
- $delta = [math]::Abs($census.Ratio - $ours) / $ours * 100.0
- Write-Host ''
- Write-Host (" TWO DIMENSIONLESS RATIOS: {0:N4} against {1:N4} — {2:N2}% apart." -f $census.Ratio, $ours, $delta)
- Write-Host ' Neither needs a shared span, and neither is derived from the other. If they agree at'
- Write-Host ' THREE settings, a drained Streamline batch is an application frame; if they agree only'
- Write-Host ' at x2, the rival that PresentMon is halving something is not excluded (S30).'
-}
-
-exit 0
diff --git a/tools/license-check.ps1 b/tools/license-check.ps1
index 5a4cd080..32e1d692 100644
--- a/tools/license-check.ps1
+++ b/tools/license-check.ps1
@@ -226,7 +226,6 @@ else {
$rows = @(Get-Content $noticesPath | Where-Object { $_.TrimStart().StartsWith('|') })
$claims = @(
@{ Marker = 'NVIDIA NVAPI SDK'; Path = 'src/native/third_party/nvapi' },
- @{ Marker = 'Intel PresentMon'; Path = 'assets/native/PresentMon.exe' },
@{ Marker = 'Vulkan headers'; Path = 'src/native/third_party/vulkan-headers' },
@{ Marker = 'NVIDIA Streamline'; Path = 'src/native/third_party/streamline' }
)