Repository navigation
docs: a proposal for a faster development loop - #2636
jordanella wants to merge 3 commits into
Conversation
|
Thanks for this. It's exactly the data Phase 0 was missing. Pushed 3c32ad6:
Yes please to upstreaming the shared-store wrapper and the in-session A/B pieces as their own PRs. We'll take Phase 0 on Windows: a no-op rebuild, a one-file renderer edit and a host header edit, with the link and compile times from today's output posted here, then A1 to cover the phases that output doesn't show. The first code PR follows from those numbers: A4 if Windows' links are slow, otherwise the rest of A7. |
A one-line renderer or host change costs a relink of the 426 MB exe, a cold start and a walk back to the scene, and a stray RX_* switch or a failed build relifts the whole game. docs/dev-loop-proposal.md plans six workstreams (the build graph, renderer and shader reload on the control bridge, host and game code, testing, diagnostics, and documentation and code maps for people and agents) as small PRs behind a week of measurement, with the release profile unchanged. Facts were read from the source at 7297d93; nothing in it was measured. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The six decisions are settled. Agents never read work/, and a table of game-function addresses stays local, so F4 is narrowed to local lookups. The entry point is nx2/dev.py, scenarios go in tests/scenarios/, warnings start advisory, there is no host split for now, and the async update check gets its own PR. From the review: - A2: the lift key leaves out path-valued variables and hashes their targets' contents, with an optional shared lift snapshot. - A10: new, an opt-in object store shared across work folders (~720 s to 18 s for a fresh worktree in a maintainer's setup), with the two catches: seed the git-ignored work/ inputs, and keep the PGO profile at a content-addressed path. - B1: a symbol check before the staged DLL swap, and dlerror()'s text in the loader's failure line. - D4/D5: in-session A/B, a fresh save per run, spread and a sanity metric in summaries. - D6: new, a lock so timing runs never share the machine with a build. - A4/A6/C2: the Linux data points. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
Phase 0 on Windows, and the two fixes it turned up. The setup: Ryzen 9 3900X (24 threads), 64 GB, NVMe work folder,
What follows from these numbers:
All numbers are from one PC, read off |
|
Claiming A3 (the emit in several processes on Windows), with it already working: the PR is #2748.
If you'd rather fold it into your step 4.1, say so and I'll adapt or close it. |
|
Thanks @jordanella—Phase 0 has already turned into useful fixes. #2674 and your A5 #2702 are merged, and @Jiro131's A3 #2748 has landed too; #2686, A7 #2675, A1 #2693 and A6 #2706 are still open. #2732 also supplies a concrete base/pack approach to the middle loop, still under review rather than something to design from scratch. My prompt skip #2698 is merged: the finish stage here went from roughly 67 s to 0.6 s on the i9-13900K/Arch source build, with other work running—not a whole-build or gameplay measurement. Its cleanup/wording follow-up #2710 remains under review, with an open finding being addressed. Only two concrete proposal details I'd still flag:
The landed/open links above would also let the proposal retire its “not started” status and keep the remaining plan short. |
|
Thanks @mooki000, both taken:
I'll refresh the proposal's status (landed, open, local) when I next push it. |
Joey-Magnus
left a comment
There was a problem hiding this comment.
I read the doc against current main and the review thread. hckrman101's points are all reflected: the decisions are recorded at the top, A2 now leaves the path variables out, B1 has the ABI check, A10 and D6 are in, and D4/D5 have the in-session A/B. The red CI is main's own breakage from early Nov 12 and has nothing to do with a docs-only change.
What I'd still change before merging:
- The status line (line 3) still says "not started". #2674 (A7's lift-key half), #2702 (A5) and #2748 (A3) are merged, and #2675, #2693 and #2706 are open. A short "done / open" list would keep the doc honest.
- D6 puts the lock "in
work/". That's one lock per worktree, but the point is that a timing run must not share the machine with a build in another checkout, so it needs a machine-wide location (as mooki000 also said). - F5 puts the index in
work/index/, while decision 1 and F6 say agents never readwork/. The tool meant for agents should keep its source-only index outsidework/.
With those fixed I'd be happy to see it merged as the plan of record.
…s nothing in work/ Joey-Magnus's points on NotRexed#2636: the status line lists what is merged, open and built; D6's lock is nx2/kit.py's .bench-lock beside the checkout (every worktree shares it), taken only by a timing run that asks for it; F5 keeps no index, so nothing goes in work/ (decision 1, F6). Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Today a one-line renderer or host change costs a relink of the 426 MB exe, a cold start and a trip back to the scene, and a stray
RX_*switch or a failed build makes the next build translate the whole game again. This adds a proposal, docs/dev-loop-proposal.md, for making those edits cheap and predictable and the code easier to navigate, without changing what players build or run.Decisions needed (top of the doc, each before its work starts):
work/, single excerpts on request, or local models only.scripts/cpu_categories.pyalready treats "a map of the game's code" as local; the same question covers a hand-written table of game-function addresses in the repo.nx2/dev.py(proposed) orscripts/dev.py.scenarios/ortests/scenarios/.What it plans, as small PRs behind a week of measurement (Phase 0):
compile_commands.json, and onenx2/dev.pywhosestatusnames why anything rebuilds.relaunchcommand on the control bridge (feat(control): drive a running game over a local socket, with a CLI #926) with a staged DLL swap in dev builds, so a renderer edit reaches a scripted scene in one command. Built-in shaders loadable from disk. A live renderer swap is designed but deferred: the renderer has no teardown today.run_all.py --changed, one shared source-cutting helper in place of about 165 copies ofblock(), a sanitizer lane, scenario files onhookshot_ctl.py, and run summaries that can be compared.docs/README.mdindex, subsystem maps, every generated file naming its generator, adev.py whererepo map that tells people and agents which tests cut the code they're changing, and the data boundary for agents written into AGENTS.md.How it scores. Under workflow.md's formula, contributor tooling is S3 with no player reach, so it shouldn't take a worklist row from anyone. The case for it is throughput. The three pieces that do reach players (the full rebuild after a failed link, the blocking update check, the single-process emit on Windows) get their own worklist rows, scored normally.
Where the facts come from. Read from the source at
7297d93d, partly by AI agents, and rechecked againstmainwhere the plan leans on it. #2324's kept lift and #2518'sCOMPILE_ONLY_ENVwere already doing parts of it, and the doc builds on them rather than re-proposing them. Nothing was measured; timings are quoted from the PRs that measured them.Testing. Docs only: one new file, no code changed. Every relative link and anchor in it resolves;
tests/test_hookshot_ctl.py(the one check that readsdocs/) passes. I didn't run the fullrun_all.pylocally, since nothing it checks changed; CI runs it. No screenshots: nothing changes on screen.🤖 Generated with Claude Code