Parent: #140 Profiles: #163, #164 Roadmap: #134
Implement the three shared Home/Bun CachedBytecode.zig imports as one exact ownership boundary:
generateCachedModuleByteCodeFromSourceCodegenerateCachedCommonJSProgramByteCodeFromSourceCodeCachedBytecode__deref
Acceptance:
- Implement the exact pinned signatures and explicit opaque-handle ownership.
- Define a versioned, endian-stable artifact with source kind, URL, source payload, lengths, and integrity digest.
- Validate ESM/CommonJS syntax through the production parser before publishing bytes.
- Keep all out-parameters cleared on failure and tolerate null/empty URL strings according to the pinned BunString ABI.
- Add allocation-failure, invalid-source, determinism, kind-separation, lifetime, and concurrent-generation tests.
- Add compiled Home/Bun consumer evidence in Debug and ReleaseSafe.
- Refresh both exact inventories, #140/#163/#164, and concise ABI documentation.
Completion evidence:
- Implementation, exact consumers, inventories, CI, and docs:
4c1b2873 - Allocation rollback and concurrency/TSan hardening:
367a3df5 - Focused unit slice: 6/6, zero failures/leaks
- Concurrent-generation TSan slice: 3/3, zero failures/leaks/races
- Home compiled consumer: 388/388 symbols in Debug and ReleaseSafe
- Dedicated Bun compiled consumer: Debug and ReleaseSafe
- Current inventories: Home 404/471 (67 pending), Bun 396/461 (65 pending), zero unclassified