Skip to content

refactor(barretenberg-rs): migrate to ipc-codegen + ipc-runtime; drop PipeBackend#23613

Open
charlielye wants to merge 1 commit into
cl/ipc-bb-migratefrom
cl/ipc-bb-rs-migrate
Open

refactor(barretenberg-rs): migrate to ipc-codegen + ipc-runtime; drop PipeBackend#23613
charlielye wants to merge 1 commit into
cl/ipc-bb-migratefrom
cl/ipc-bb-rs-migrate

Conversation

@charlielye

@charlielye charlielye commented May 28, 2026

Copy link
Copy Markdown
Contributor

Summary

Migrates barretenberg-rs to the generated bb API client from #23612 and the shared /ipc-runtime Rust bindings from #23610.

This PR sits between the bb server migration and the bb.js migration.

Stack

  1. feat(ipc): add /ipc-codegen and /ipc-runtime foundation packages #23610 cl/ipc-foundation
  2. refactor(wsdb): migrate aztec-wsdb to ipc-codegen + ipc-runtime #23611 cl/ipc-wsdb-migrate
  3. refactor(bbapi): migrate bb binary to ipc-codegen + ipc-runtime #23612 cl/ipc-bb-migrate
  4. refactor(barretenberg-rs): migrate to ipc-codegen + ipc-runtime; drop PipeBackend #23613 cl/ipc-bb-rs-migrate — this PR
  5. refactor(bb.js): migrate to ipc-codegen + ipc-runtime; delete legacy bb::ipc #23614 cl/ipc-bb-js-migrate
  6. refactor: cut TS world state and NAPI AVM over to WSDB IPC; delete NAPI WSDB #23036 cl/ipc-3-avm-wsdb-cutover
  7. feat: add aztec-avm + aztec-cdb binaries and IPC supporting code (inert) #23084 cl/ipc-4-avm-binary
  8. feat: AVM cutover — delete NAPI AVM, wire IPC simulator pool + CDB IPC server [PR 3b] #23697 cl/ipc-5-avm-cutover

What changes

  • Generates Rust bb types and client code from bb_schema.json.
  • Uses the generated BbApi over ipc_runtime::IpcClient.
  • Removes the old hand-written Rust backend/types/error layers.
  • Removes the legacy PipeBackend; Rust clients now use the IPC runtime path.
  • Keeps the FFI entrypoint conventional and non-configurable.
  • Updates tests for fixed-size bin32/alias handling from the schema.

Validation

  • barretenberg-rs release build with local BB_LIB_DIR.
  • Rust tests adjusted for generated fixed-size values and conventional FFI entrypoint.

@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from a4bbaea to 14f9b51 Compare May 28, 2026 06:19
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from e77abcf to 7e96565 Compare May 28, 2026 06:19
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 14f9b51 to c1eac55 Compare May 28, 2026 07:10
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 7e96565 to 1613aa0 Compare May 28, 2026 07:10
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from c1eac55 to 3ae8af4 Compare May 28, 2026 09:26
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 1613aa0 to c0dc6a8 Compare May 28, 2026 09:26
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 3ae8af4 to 34d56b4 Compare May 28, 2026 09:40
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from c0dc6a8 to fc07715 Compare May 28, 2026 09:40
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 34d56b4 to 66ffb2b Compare May 28, 2026 10:43
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from fc07715 to be7439e Compare May 28, 2026 10:43
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 66ffb2b to 2793608 Compare May 28, 2026 11:07
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch 2 times, most recently from be7439e to e456007 Compare May 28, 2026 11:07
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 2793608 to e4043d1 Compare May 28, 2026 11:24
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from e456007 to 9f87d9a Compare May 28, 2026 11:25
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from e4043d1 to ecae1fa Compare May 28, 2026 11:39
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 9f87d9a to bfa811c Compare May 28, 2026 11:39
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from ecae1fa to 396a0f4 Compare May 28, 2026 12:23
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 04190be to 589e5ef Compare May 28, 2026 16:24
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 589e5ef to 02d0e6f Compare May 28, 2026 17:29
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 02d0e6f to bf22e83 Compare May 28, 2026 17:35
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from da691d1 to dfacac4 Compare May 28, 2026 17:37
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from bf22e83 to e40c637 Compare May 28, 2026 17:37
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from e40c637 to 418aa6a Compare May 28, 2026 18:03
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
charlielye added a commit that referenced this pull request May 28, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
charlielye added a commit that referenced this pull request May 29, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
charlielye added a commit that referenced this pull request May 29, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
charlielye added a commit that referenced this pull request May 29, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 7afda83 to 8188c34 Compare May 29, 2026 12:09
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from e220e59 to 0c02156 Compare May 29, 2026 12:09
charlielye added a commit that referenced this pull request May 29, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
@charlielye charlielye force-pushed the cl/ipc-bb-migrate branch from 8188c34 to fb1beea Compare May 29, 2026 12:17
@charlielye charlielye force-pushed the cl/ipc-bb-rs-migrate branch from 0c02156 to 6f36fc6 Compare May 29, 2026 12:17
charlielye added a commit that referenced this pull request May 29, 2026
…bb::ipc

Last PR in the IPC migration stack (base: #23613 barretenberg-rs).
Cuts bb.js's TS surface + its NAPI substrate over to the foundation
packages (PR #23610). Two backends:
- WASM (`bb_backends/wasm.ts`): uses `cbindCall('bbapi', bytes)`
  via WASM exports. The C++ side (in PR #23612) pipes bytes through
  codegen `make_bb_handler`. No TS-side changes — wire-compatible.
- Native UDS / SHM (`bb_backends/node/native_socket.ts`): uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.

**TS**:
- `barretenberg/ts/scripts/generate.sh`: regen script that calls
  `node ipc-codegen/src/generate.ts` for bb (TS + Rust bindings) and
  for aztec-wsdb (TS bindings).
- `barretenberg/ts/src/cbind/`: codegen sources moved into
  `/ipc-codegen/src/` in PR #23610. The deletions land here. The
  generated/ subdir is gitignored and regenerated by the bb.js build.
- `barretenberg/ts/src/bb_backends/node/native_socket.ts`: uses
  `UdsIpcClient` from `@aztec/ipc-runtime`.
- `barretenberg/ts/package.json` / `yarn.lock`: depend on
  `@aztec/ipc-runtime`.
- `barretenberg/ts/src/bbapi/chonk_pinned_inputs.test.ts` deleted (drift
  from the original stack rebase — referenced obsolete domain command
  types).

**C++ NAPI substrate**:
- `barretenberg/cpp/src/barretenberg/nodejs_module/msgpack_client/`:
  `msgpack_client_{wrapper,async}.{cpp,hpp}` use
  `ipc_runtime/ipc_client.hpp` for transport.
- `barretenberg/cpp/src/barretenberg/nodejs_module/CMakeLists.txt`: link
  `ipc_runtime`.

**Legacy ipc subdir gone**:
- `barretenberg/cpp/src/barretenberg/ipc/` removed entirely.
  After this PR no consumer references `bb::ipc::` — every transport
  surface routes through `ipc::` from ipc-runtime.
- Top-level `barretenberg/cpp/src/CMakeLists.txt`: drop the
  `add_subdirectory(barretenberg/ipc)` and the transitional comment
  about the legacy subdir.

Verification:
- `ninja bb aztec-wsdb bbapi_tests` clean (legacy bb::ipc gone)
- `./bin/bbapi_tests` — 30/30
- `cd barretenberg/ts && yarn build && yarn test`
- bb-prover e2e against migrated bb.js

End state after the full 5-PR stack:
- bb / wsdb servers route through codegen `make_<prefix>_handler` +
  `ipc::make_server` + `ipc::install_default_signal_handlers`.
- bb.js / barretenberg-rs clients route through codegen-emitted typed
  surfaces over `ipc_runtime::IpcClient` (Rust) /
  `@aztec/ipc-runtime`'s `UdsIpcClient` (TS).
- No `msgpack_roundtrip` at handler boundaries.
- No parallel domain command types.
- No hand-rolled UDS/SHM transport.
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