Review large AI-generated areas without trusting them

CNA snapshot 3b43bd86  ·  Development › Human Takeover  ·  source links pinned to 3b43bd86

✓

Evidence basis: source-verified at the pinned commit; tests exist (not executed for this page). Claims on this page were checked by reading the CNA source at commit 3b43bd86; unless a sentence says otherwise, nothing here was built or executed. Counts come from the TARGET tree and Git objects; guards were read from CMake, scripts and workflows, not run. Test outcomes quoted from merge messages and plans are CNA's own records, not reproduced. Renderer identities that CNA has retired are deliberately not named.

CNA was built at scale with AI assistance, and the tree carries the paper trail: commit subjects with task IDs, 62 plan files, root-level handoff and campaign records, and comments that cite tasks. This page says how far each of those can be trusted, which of CNA's own mechanical guards are stronger evidence than any prose (and what each one really enforces), and how to review a very large diff without trusting its author, using one of the campaign merges in the snapshot's history as the worked example. Read it before you accept a change because a plan row, a status banner or a comment says it is done.

The rule

Current source and active CMake are authoritative. Plans, audits, handoff notes and comments explain intent and history, and can be stale. CNA's own files say the same about themselves. plans/README.md says the status recorded inside each plan is authoritative and refuses to copy task counts into the index, and several plans open with a banner that marks them superseded or historical (for example plans/plan_ascii.md and plans/plan_glbackends.md); finished or superseded plans are also deleted outright, with Git history keeping them (on 26 October 2026 alone, plan_graphics.md, plan_sdl3free.md, plan_vulkan_parity.md and four others). AGENTS.md and CLAUDE.md tell an assistant not to treat “old CNA code or AI-generated stubs” as authoritative when they conflict with the FNA reference API.

In practice: behaviour is answered by the implementation, the active CMake that compiles it and the tests registered for a given configuration; why, by git log and the plan; whether something is supported, by the registry (cmake/RendererIdentities.cmake), the CI workflows and Known uncertainty and history.

How the assistance shows in the tree

The instruction files address assistants directly (porting conventions, CNAEXT tagging, “always commit after finishing a task”), and handoff.md opens with an “Exact next task” written for the next session. Those are instructions to a past or future agent, not project policy and not authorization for you. Git cannot separate assistant-written from human-written work: all 10,679 reachable commits carry one author name, none of the 4,657 commits since the v0.1.0-alpha.1 tag has a Co-authored-by trailer, and 4,154 of those 4,657 carry a signature header (212 of them SSH rather than PGP signatures), which attests the committing key and not that anyone read the diff.

The artifacts and how far each can be trusted

Figures were counted from the TARGET tree and history at 3b43bd86; patterns are simple, so treat the percentages as approximate.

ArtifactWhat it is at the snapshotUse it forDo not use it for
Commit subjects and task IDs4,657 commits since the alpha.1 tag; 4,242 subjects follow type(scope): (for example perf(Task WEBGPUPERF-0006): one command encoder per frame; a render-target cycle no longer submits); 916 carry (Task …) or (Tasks …); by a simple pattern, about 3,670 (79 %) contain a PREFIX-number token. AGENTS.md asks for one task per commit, yet 30 (Task …) subjects use a range, the widest, MOD-713..MOD-731, naming 19 IDs, and one merge subject, merge(WIN11-0003..0103), names 101.Finding the plan that holds the evidence: FX-0nn is plans/plan_fx.md, SDLGPU-nn is plans/plan_sdlgpu.md, SOFTWARE-nnn is plans/plan_software.md, AM4-nnn is plans/plan_apple_m4.md.Scope, or proof that the plan still exists: one commit can carry 19 IDs, and a plan can be deleted while its IDs live on in subjects and comments (WEBGPUPERF, SMG, STREETS and WGF named plans that are no longer in the tree; Git history keeps them).
First-parent merges2,113 first-parent commits since the tag: 2,061 direct commits and 52 merges (69 merges in all, 31 named merge(<Campaign>)). The other 2,544 commits sit inside merged branches.The integration story: what landed when, and the summary numbers in merge messages.The content of a “fold” merge, which can carry edits no branch commit shows (worked example below).
Plans62 Markdown plans and an index in plans/, each a table of task rows with status and evidence; a few open with a superseded or history banner.Intent, the decision trail, what was measured on which host, and where CNA recorded its own corrections.Current behaviour or “done”. See the examples below the table.
Handoff and campaign recordshandoff.md (524 lines): the current status, where information lives, the working rules and the known defects and limitations (§5), plus a repair-campaign section dated 2026-10-24 with an “exact next task”; CNA_ENGINE_REPAIR_HANDOFF.md and CNA_DEMOS_REPAIR_MATRIX.json track the engine and demos repair campaigns (the demos and museum repair handoffs and the inherited review were removed on 2026-10-25; Git history keeps them); CHECKLIST.md is the per-file porting checklist. The per-file audit archive, the remediation tasks, the modularization inventories, NEXT.md, AUDIT.md, TODO.md and the known-bug lists of earlier snapshots are no longer in the tree; Git history keeps them.Dated context, the reasoning behind a change, and what CNA itself lists as open.Live status without a date: handoff.md was last changed by the TARGET commit itself (3b43bd868, 2026-10-27), yet its campaign section is dated 2026-10-24 and its defect list (§5.1, none open) was reconciled the same day; a later commit can have changed what it describes.
Spikesspikes/: 21 probe directories. CLAUDE.md keeps a probe while its subject is a candidate or supported and removes it on retirement.A recorded measurement (the seven xna-*-spike probes).Current behaviour.
Documents in docs/142 Markdown files at the top of docs/ (181 with its subdirectories). Some are dated measurement reports (docs/d3d9-divergence-report.md: “Status: 2026-07-15”, 31 scenes); some are living design pages (docs/opengl33-renderer.md, docs/physical-modules.md, docs/link-size-architecture.md).Rationale and dated evidence, after reading the status line.A count or table you have not compared with the registry or CMake.
Instruction filesAGENTS.md has 498 lines and CLAUDE.md 649; they have diverged (see the drift table).The conventions the code was written under.A description of the code, or of the current FNA/XNA tie-break.
Comments citing tasks1,613 files under modules/, cmake/, scripts/, tools/, tests/ and examples/ cite a plans/plan_*.md path: 4,616 citations of 70 plans.Which campaign to read and why a line exists.The comment's claim about behaviour. 413 of those citations name 30 plan files that do not exist at TARGET: most were deleted in the October clean-ups, and the four plan_devices_phase*.md files that commit 4cb7578b6 (“Old plans were deleted”) removed from the repository root on 2026-07-07 are still cited under a plans/ path they never had, including in doc comments of the public headers Accelerometer.hpp, Gyroscope.hpp and SensorBase.hpp.

Plan rows are claims, and CNA's plans record their own corrections. SOFTWARE-375, 376 and 390 were closed as done, and SOFTWARE-457 (2026-09-12) records that Microsoft's assembler invalidated the evidence behind them: the fixtures used operand forms the compiler forbids, and both CNA compile paths had accepted seven forged violations (plans/plan_software.md). plans/plan_webgpu.md has 201 done rows and one partial one (counted from its own row tables with the logic of tools/count_webgpu_plan_status.sh) and says “read the row count as a count of rows, not as a parity claim”; a later plan, plans/plan_webgpu_failing_eight.md (no longer in the tree), recorded that ctest -L WebGPU had eight failures on rows marked done, three of them tests asserting behaviour the framework had deliberately changed: “a plan row being green says the work was done, not that the test still describes the framework it was written against.”

Drift found while verifying these pages

Each row was checked by reading the named source at 3b43bd86. It is a sample, not a census; the point is the shape of the mismatch.

Where the claim livesWhat TARGET does
The IsLatched() comment in GraphicsRendererSelection.hpp: the selection latches when the first GraphicsDevice begins construction.GraphicsDevice::resolveRenderer in GraphicsDevice.cpp calls GraphicsRendererSelectionAccessEXT::Latch only after a candidate renderer was created, and its own comment says latching up front “was the first cut, and it was wrong”. Two comments disagree; behaviour follows the implementation (latch internals).
The device-status comment in GraphicsDevice.cpp (getGraphicsDeviceStatusProperty) says every renderer except Direct3D 9 never calls the device-event callback.DirectX9 and WebGPU call it (WebGPU only from its debug hooks), as the member comment on deviceStatus_ in GraphicsDevice.hpp now says.
A comment in Sdl3Platform.cpp cites Game::UpdateInput().No such function exists under modules/; the pump is the tail of Game::PollEvents.
Stale counts in prose: check_renderer_descriptors.py says a build “compiles all 45”; the header of general-tests-ci.yml says “all 14 renderers”.The registry holds 10 identities over 8 families. The enforced number lives in the table inside check_renderer_identities.py. CNA's own row RTR-P13-8 (plans/plan_runtimerenderer.md) says a count in prose is “a fact with no owner”.
PlatformHotPathLint.cmake contrasts itself with a ratchet that “warns because the whole tree is over budget by design”.PlatformRatchet.cmake defaults CNA_PLATFORM_RATCHET_STRICT to ON, and sdl_budget.json records a budget of 0 files and 0 references with an irreversible floor of 0.
cross-renderer-parity-fixtures.md: the “Current fixtures” table lists 13.ParityFixtures.cmake lists 32 fixtures; the three families the document names (EasyGL, WebGPU and SDL_GPU) are the ones that call cna_register_parity_fixtures().
run-oracle-corpus-diff-easygl.sh defaults DISPLAY to :0, calling that “this project's own CNA_TEST_DISPLAY default”.Since GTI-0001 that variable defaults to empty (TestDisplayPolicy.cmake), and CLAUDE.md forbids running oracles on the owner's live desktop; the script still falls back to :0 when DISPLAY is unset (by reading; not executed).
AGENTS.md calls FNA “the authoritative behavioral and API reference”.CLAUDE.md calls it the “working” reference and adds a tie-break decided on 2026-09-04 (0e62e7368): where measured Microsoft XNA and FNA disagree, CNA follows XNA. AGENTS.md has no such section, defers to CLAUDE.md for layout and lacks the Platform Boundary chapter; CHECKLIST.md says FNA is authoritative for behaviour and the XNA reference assemblies for API surface.

CNA's mechanical guards: what each really enforces

A guard is stronger evidence than prose only for what it matches, in the configuration that runs it, and with the exit code it actually produces. The table gives, for each, when it runs, what it enforces and what it cannot see. Registrations were read from CMake and workflows; nothing was executed.

GuardRunsEnforcesBlind spot
scripts/check_renderer_identities.pyCTest RendererIdentityRegistry; a step in multi-renderer-ci.ymlThe 10 identities agree across the enum, the CMake list and the runtime registry chain; C ABI values are pinned and retired ones reserved; retired names are not selectable; counts stated in docs/runtime-renderer-selection.md, docs/physical-modules.md and plans/plan_platform.md match.Counts only in those listed files and only in the phrasings “N public identities” and “N implementation families”; LIMITATIONS.md and comments are outside it. A fourth listed document no longer exists and is skipped without a message.
cmake/RendererIdentities.cmake and the CnaRendererRetired_* script-mode testsConfigure time; CTestAn unknown renderer name given to CNA_GRAPHICS_RENDERER or as a member of CNA_GRAPHICS_RENDERERS is refused by name, and a retired name on every route (also CNA_RENDERER_<X>); an unknown CNA_RENDERER_<X> switch is not checked. One test per retired identity is generated from the list, plus a list of route and control cases (a refused name on each route, and live names that must be accepted).Says nothing about a public renderer's quality.
cmake/RendererDescriptorGate.cmake, with scripts/check_renderer_descriptors.py and scripts/check_runtime_renderer_discipline.pyConfigure time (CNA_BUILD_RENDERER_DESCRIPTOR_GATE defaults ON); check_renderer_descriptors.py as a step in multi-renderer-ci.yml (no CTest registers it at this snapshot); CTest RuntimeRendererDisciplineEvery family's descriptor translation unit is compiled in every configuration (an object library nothing links); a registered identity without a matching descriptor namespace fails configure; no CNA_RENDERER_* macro may appear in modules/graphics/src/.Compiles descriptors, does not check what they answer. DIRECTX9's descriptor is compiled only by its own family build.
cmake/PlatformRatchet.cmakeConfigure time; on by default and strict by defaultSDL references in production files outside the allowlist must stay at zero (tools/platform/sdl_ratchet.py, budget file at 0/0); a separate audit classifies test and example uses.A textual match, comments included. Skipped with a status line when Python 3 is absent; passing results are cached by input fingerprint.
cmake/PlatformHotPathLint.cmakeConfigure time, hard errorNo platform call through a platform receiver inside a loop whose header mentions per-pixel, per-vertex, per-fragment, per-sample or per-event tokens; an annotation needs a reason.Its own docstring: both judgements under-report, so a pass is not proof.
cmake/TestDisplayPolicy.cmakeConfigure time; CTests CnaTestDisplayPolicy, CnaTestDisplayPolicyAsSubproject, CnaTestDisplayIsolationRegistered tests do not target the live desktop: CNA_TEST_DISPLAY is empty by default, :0 needs CNA_TEST_ALLOW_LIVE_DISPLAY=ON, every test carries a Wayland guard (non-Windows); the last test inspects ctest --show-only=json-v1 of the configured tree.Registrations, not what a script does inside a test (see the :0 fallback above). The last two need CMake 3.28 or newer.
cmake/Tests/ModuleProbes.cmake with scripts/check_module_link_closure.pyCTest, native builds with tests onUp to 15 minimal probes, one per module alias; the probe's link line must not contain forbidden archives (and must contain required ones). A native-SDK-free gate exists for single-renderer HEADLESS builds, and XML-free gates cover twelve probes.Reads CMakeFiles/<target>.dir/link.txt and exits 77 (skip) without it; the unit, tests, multi-renderer and cnaext presets and the general-tests and multi-renderer workflows all use Ninja, and no workflow names these tests.
scripts/check_no_posix_setenv.pyNowhere: no CMake file or workflow registers it at this snapshot, so it runs only by handWhen run: no setenv or unsetenv outside comment lines in modules/, tools/, tests/ (they do not exist on MinGW-w64).Everything, while nothing runs it: by reading, three Storage test sources contain such calls at TARGET, and no gate reports them.
tools/xnb/check_plan_status.py, tools/count_webgpu_plan_status.sh, the CApiLimitations and CApiDocExportCounts testsThe XNB plan check: CTest CnaXnbPlanStatusConsistency; the WebGPU counter: by hand; the C API tests: CTestA plan's stated totals agree with its own task table, and no line contradicts a closed decision (the XNB pipeline plan only); status counts derive from rows; C API document counts derive from the inventory.Rows, not behaviour: a green row can stay green after its test breaks.
tools/audit_xna_runtime_surface.pyManual; not registered by CMake or a workflow (searched)A census of documented XNA types and members against CNA's public headers.Representation only; its default input is a directory beside the repository.

Sibling audits in the same style are scripts/check_renderer_target_discipline.py (RendererTargetDiscipline), scripts/check_renderer_combinations.py (RendererCombinationRegistry) and scripts/check_removed_renderer_api.py (RendererCurationApiDecisions). The CNAEXT guard, matrix, naming, nodiscard and Doxygen checks (scripts/check_cnaext_guards.sh and its neighbours) are still in the tree, but no CMake file or workflow runs them at this snapshot.

Three reading rules follow. Know when a guard runs: configure time, CTest, CI or by hand. Know what it matches: a regular expression, a compile, or a registration list. Know how it fails: skip or fail, and which condition sets the exit status. The last matters most for oracle scripts, where a printed difference does not always produce a non-zero exit; the oracle page gives the case.

A review method for a big diff

  1. Read the campaign structure first. git log --first-parent --merges <base>..<head> lists the integration story. For one merge M: git rev-list --count M^1..M^2, git diff --shortstat M^1 M, and git diff-tree --cc -r --name-only M, which lists the files the merge itself edited relative to both parents. Then open the plan that the branch name or IDs point to and compare its stated scope with the commits.
  2. Map changed paths to owners. Group git diff --numstat by module directory and look each owner up in Source ownership. Shared modules (modules/graphics tests and headers) mean every renderer is in scope even when the title names one.
  3. Read the tests before the implementation. Which existing tests changed expectations, and does the message name a measurement (a real-XNA probe, a task ID) or merely a new result? Check where each test is registered: renderer gate lists such as CNA_RENDERER_IS(…), the source filters in cmake/UnitTests.cmake, and the skip convention.
  4. Extract the invariants the change relies on (architectural invariants) and find a test for each: per-device GL contexts, compute bindings restored after a dispatch, the selection latch, ownership order (ownership map).
  5. Check comment and behaviour drift in the touched files. Header doc against .cpp comment against code; prose counts against registrations and lists; task citations that resolve to nothing.
  6. Look for hedged evidence. “Measured” against “reasoned”, “expected”, “should”, “not measured”; a claim with no command or test; one GPU, one driver, one date. tools/xnb/check_plan_status.py is a model of the rule: a plan's stated totals and its closed decisions must agree with its own rows.
  7. Distrust “all tests pass” without a configuration. Ask for renderer, platform, audio option, generator, display, skips and known failures (reporting evidence honestly).
  8. Record what you could not verify (investigation record), including hardware you lack and numbers you could only cross-check.

Worked example: reading a campaign merge, 0f690d7d5

The WebGPU per-draw binding campaign reached next as merge(WebGPUPerf), 2026-09-27, an ancestor of this snapshot. The commands are those of the method; the numbers were counted from Git objects.

Structure

The first parent is b1e4a2414, the tip of next at the time; the second is 196b14bd0 (WEBGPUPERF-0006). The merge base is 85c3baa09, the commit that had already put WEBGPUPERF-0001..0004 on next directly, and next had moved three commits past it, so the branch is a linear stack of five commits on that base. git diff-tree --cc lists no file: the merge commit edits nothing of its own. The message claims WEBGPUPERF-0005..0008; the five commits carry exactly those four IDs, one of them in a documentation commit that records what the ShaderEffect and compiled-effect routes still cost per draw, and the campaign's plan, plans/plan_webgpu_perf.md (in the tree at the merge, deleted before this snapshot), had rows 0001 to 0008, every one with a commit. Compare the fold merges of other campaigns, whose merge commits can carry edits that no branch commit shows.

Owners

git diff --shortstat b1e4a2414 0f690d7d5 reports 15 files, +1,505 and −548 lines. By directory: modules/renderers/webgpu/src 4 files (+719, −486), its include 2 (+166, −12), its examples 7 (+432, −41) and its tests 1 (+114), and the plan (+74, −7). A merge titled for one renderer that stays inside that renderer's directory is the narrow case: no shared test, header or module outside the family moved, so the blast radius is the WebGPU paths of the stock effects, SpriteBatch, ShaderEffect and compiled effects, which the message names. The first half of the campaign, 85c3baa09, had the same shape (7 files, all under modules/renderers/webgpu and the plan).

Checks that cost nothing

  • Tests before implementation. The merge extends webgpu_binding_cost_test.cpp by 365 lines; it is registered as the CTest WebGPU_BindingCost (label WebGPU) in webgpu/examples/CMakeLists.txt. Its header lists checks A to O, and each pair pins both halves of the change: a draw still puts its own colour in its own cell, and a steady frame creates no bind group and makes a number of queue writes that does not grow with its draw count; a texture re-created every frame never meets a stale cached group; four render-target cycles before the back buffer are one submission, and a SetData between two of them lands in order. The cost checks read the renderer's own counters, so they prove the counters, not wall-clock time, and the program needs a display and a WebGPU adapter: a host without them says nothing. The merge also adds one GoogleTest case, WebGPUCompiledEffectDrawTest.SteadyDrawsBuildNoGroupsAndCopyNoGeometry, which skips unless the build selected the WebGPU renderer.
  • Numbers in the message against the tree. “CnaGraphicsExtTests 73 + 3 HLSL skips” sums to 76, exactly the static test-definition count under modules/graphics-ext/tests/ at the merge, which a WebGPU-only diff should leave untouched. “CnaRendererTests 273” cannot be checked against a static count: the renderer test directories hold 1,029 definitions in 69 files at the merge, and the source filters in cmake/UnitTests.cmake decide which of them a WebGPU build compiles. “ctest -L WebGPU 147/147” was not recounted, and “the same 20 pre-existing failures” of CnaGraphicsTests are not named, so the message alone cannot show that no new failure replaced an old one.
  • A claim about the parts not changed. The message says “next already carried 0001-0004 (85c3baa09)”; git merge-base returns exactly that commit, which confirms the split of the campaign across a direct commit and a merge.

What stays unverified

Every pass, fail and skip count, the street frame times (91–95 ms before, 26–29 ms after) and the render-target switch cost (about 57 µs before, about 16 µs after) are CNA's records from one Linux development host with wgpu-native and from one application, street-simulator (then cna-street); none was reproduced, and none says anything about the browser build, where WebGPU goes through Emscripten's port. The WebGPU family has no internals page here; its place among the families is on the renderer family map.

Short checklist

  • Which file decides the behaviour: source, active CMake, a registered test? Not a plan, note or comment.
  • Which merge or campaign brought it in, did a fold merge edit files on its own, and which owners and renderers does it touch beyond the one in the title?
  • Did any test expectation change, and is the reason a measurement or merely a new result?
  • Which invariant does the change rely on and which test pins it; do header docs, comments and behaviour agree; do stated counts match a registry?
  • Is each evidence claim measured, dated, and tied to a host and a configuration?
  • Would the guard that covers this area run in your configuration, and would it fail on this change?
  • What did you not verify, and who can?

Limits of this page

Nothing was built or run; every statement was checked by reading files and Git objects at 3b43bd86. The drift table is a sample, percentages come from simple patterns, and the guard descriptions state registrations and script logic, not outcomes at this snapshot. Which files an assistant wrote is not recoverable from Git and is not claimed. The oracle-specific evidence rules are on Using the XNA oracle as evidence.

The same subsystem is explained at four altitudes. These are the neighbouring pages at each one.