Skip to content

Track→DAG hierarchy (#354) + Critical Path rework + scheduler fixes - #356

Merged
nockawa merged 1 commit into
mainfrom
feature/354-track-dag-foundations
May 17, 2026
Merged

nockawa merged 1 commit into
mainfrom
feature/354-track-dag-foundations

Conversation

@nockawa

@nockawa nockawa commented May 17, 2026

Copy link
Copy Markdown
Collaborator

Implements #354 — the Engine → Track → DAG → Phase → System partitioning hierarchy (W1–W6), plus Critical Path / scheduler fixes that landed alongside it.

Track→DAG hierarchy (#354)

  • Runtime exposes Engine → Track → DAG → Phase → System; apps declare tracks via RuntimeSchedule.DeclareTrack. Flat RuntimeOptions.Phases / DefaultPhase removed.
  • Fence migrated to a normal DAG on the built-in Engine-Post track (InternalScheduleBuilder / .Internal() retired).
  • Trace format: new TrackRecord / DagRecord tables + SystemDefinitionRecord.DagId; reader/writer/header updated.
  • Workbench DTOs/API: TopologyDto + ProfilerMetadataDto gain Tracks[] → Dags[] and SystemDefinitionDto.DagId; new TrackHierarchyProjection; orval regen.
  • System DAG panel: hierarchical Track→DAG→Phase grouping; "show engine systems" toggle (new useViewOptionsStore + Options DAG form); engine tracks hidden by default.
  • Critical Path panel: track-aware per-track traceback, track selector + Tracks band.

Critical Path / scheduler fixes (same branch)

  • Scheduler readyUs fix — stamp a successor's ready time at predecessor completion, not mid-fan-out; corrects both OnSystemComplete and the single-threaded path (CP gating was mis-measured).
  • WriteTickFence — scope the profiler phase marker to the serial prep only, excluding the Fence DAG dispatch (was double-counting the Fence systems into writeTickFenceUs).
  • Critical Path view — reworked to a clip-and-pan timeline (no horizontal scrollbar, wheel pans) instead of native scroll; worker-claim-wait hatch restricted to the CP track.

Other

  • Spatial perf: per-cell scan cursor collapses cluster slot-claim from O(M²) to O(1) amortized.
  • EcsQuery: pre-size the View entity-id set to its final count.
  • AntHill demo + engine test suite migrated to the Track/DAG API.

Docs (overview/13-runtime.md, ADR 052) are in the companion typhon-claude PR.

🤖 Generated with Claude Code

  - Track→DAG hierarchy (#354): runtime exposes Engine→Track→DAG→Phase→System; apps declare tracks via RuntimeSchedule.DeclareTrack; Fence migrated to a normal DAG on the Engine-Post track; flat RuntimeOptions.Phases/DefaultPhase removed.
  - Trace format: new TrackRecord/DagRecord tables + SystemDefinitionRecord.DagId; reader/writer/header updated.
  - Workbench DTOs/API: TopologyDto + ProfilerMetadataDto gain Tracks[]→Dags[] and SystemDefinitionDto.DagId; new TrackHierarchyProjection; orval regen.
  - System DAG panel: hierarchical Track→DAG→Phase grouping; "show engine systems" toggle (new useViewOptionsStore + Options DAG form); engine tracks hidden by default.
  - Critical Path panel: track-aware per-track traceback, track selector + Tracks band; timeline reworked to clip-and-pan (no horizontal scrollbar, wheel pans) instead of native scroll; worker-claim-wait hatch restricted to the CP track.
  - Scheduler readyUs fix: stamp a successor's ready time at predecessor completion, not mid-fan-out — corrects both OnSystemComplete and the single-threaded path; CP gating was mis-measured.
  - WriteTickFence: scope the profiler phase marker to the serial prep only, excluding the Fence DAG dispatch — stops double-counting Fence systems into writeTickFenceUs.
  - Spatial perf: per-cell scan cursor collapses cluster slot-claim from O(M²) to O(1) amortized; full-cluster scan reads non-dirty.
  - EcsQuery: pre-size the View entity-id set to its final count (one POH allocation instead of incremental resizes).
  - Workbench files UI: shared lib/formatters.ts; FileBrowser/RecentFiles show size + last-modified columns.
  - AntHill demo + engine test suite migrated to the Track/DAG API.
@nockawa
nockawa merged commit 9db513f into main May 17, 2026
6 checks passed
@nockawa
nockawa deleted the feature/354-track-dag-foundations branch May 17, 2026 20:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant