pcbjam/docs
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Gergő Törcsvári 54e6560037
docs 22: Phase E first attempt (K1 as a context wait) - REVERTED, with the post-mortem
Converting the symbol-library bridge from one EM_ASYNC_JS into
beginWait -> start -> wxWasmYieldUntil -> take_result made the app hang after
every library request: the KiCad suite went from 7 minutes to 1.2 HOURS, 111
passed with the rest timing out, and the log goes silent right after a lib
request - a parked context nobody resumes. Reverted; the tree keeps the
working EM_ASYNC_JS and no code from the attempt.

Recorded for the next attempt:

- The PRECONDITION it found (four lines, quoted in the doc, deliberately NOT
  landed): wxWasmYieldUntil must not park a context whose wait is already
  resolved, because resolveWait deletes the entry. The in-place form had no
  such window; every bridge in this pattern re-opens it. It was not the hang,
  but it has only ever existed in the broken build, so it lands WITH the
  conversion it protects, not before.
- Three hypotheses in evidence order, cheapest first: the resolve never
  reaching the registry (this is the first KiCad-side caller of the wait
  registry - check Module["_wxWasmSchedResolveContextWait"] exists in the
  KiCad link); the lib request running inside the chooser's modal where the
  dispatch context is ALREADY parked on a nested wait (a context holds one
  park); or the Asyncify instrumentation closure shifting when the
  EM_ASYNC_JS left that translation unit.
- Process: gate a bridge conversion on a SINGLE spec, never the full suite.
  This cost a 1.2-hour run to learn one bit.

Tree is unchanged from the last verified landing state (STAR_DISPATCH=0,
kicad 139 passed / 1 pre-existing occ-probe) - docs only.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01LBjomQfKyRa3jBdeAKpmTw
2026-08-10 10:14:19 +02:00
..
debugging docs: ✏️ cleanup and organize docs 2026-06-05 12:16:13 +02:00
features docs 22: Phase E first attempt (K1 as a context wait) - REVERTED, with the post-mortem 2026-08-10 10:14:19 +02:00
research docs: ✏️ cleanup and organize docs 2026-06-05 12:16:13 +02:00
build.md refactor: collapse dual-mode plumbing — the DOM port is the only WASM build 2026-06-12 20:19:48 +02:00
ci-build-slowness-findings.md docs: CI build perf findings + parked wasm-exceptions experiment 2026-06-11 07:50:57 +02:00
README.md docs: ✏️ cleanup and organize docs 2026-06-05 12:16:13 +02:00
wasm-exceptions-experiment.md feat(wasm-eh): migrate the WASM build to native wasm exceptions (+ 3D viewer default-on) 2026-06-30 09:40:26 +02:00

Documentation Map

A central index of the documentation in this repo. The goal of the project is to build KiCad with WASM and run it in a browser.

Note: per-area README.md files stay next to the code they describe (they're linked below). Cross-cutting guides live under docs/. Per-feature design notes live under features/.

Start here

  • Project README — overview, prerequisites, quick start, project structure
  • CLAUDE.md — project/agent context and contribution conventions

Build

  • docs/build.md — Docker-based KiCad WASM build system (two-phase build, outputs, memory)
  • docker/README.md — Docker build environment, branch-specific containers, troubleshooting
  • wasm/README.md — WASM compatibility layer (overrides/shims without patching KiCad)

Debugging & Asyncify

Architecture

  • wasm/README.md — WASM compatibility layer structure
  • web/README.md — web app (create/open KiCad projects), tech stack, URL routing, WASM artifact serving

Testing

Feature design docs

Per-feature design notes and porting records live under features/:

Archived / historical

features/archive/ holds docs whose work is done or superseded (each carries a status banner):

  • webgl — WebGL-GAL strategy/plan (since implemented in kicad/common/gal/webgl/)
  • ipc-api — IPC-API guard cleanup TODO (revert not yet actioned)