Skip to content

perf: benchmark kernal-api compilation boundaries and release packaging #3

Closed

Description

@zackees

Context

kernal-api needs one stable public API, but that does not decide whether its implementation should be one crate, private leaf crates, or a release amalgamation. The canonical ownership and dependency direction are defined by #1 and ARCHITECTURE.md; packaging is a compile-performance decision.

Proposal

Benchmark a small number of packaging shapes against the same public facade and feature graph:

  1. cohesive modules in one package;
  2. a few coarse private implementation crates with stable facade types;
  3. release amalgamation only if it measurably improves distribution or build behavior.

Use first-party client workloads and Soldr's cache instrumentation. Measure clean builds, common incremental edits, feature-minimal builds, final linking, artifact size, and cache reuse. Verify that disabled features physically omit their dependency trees.

Acceptance criteria

  • A checked-in benchmark protocol records toolchain, host, commands, feature sets, and repeated measurements.
  • RED -> GREEN dependency checks prove disabled capabilities do not enter the resolved graph.
  • Results compare clean time, incremental critical path, peak memory, cache hit/reuse, and output size for each candidate.
  • Any selected private crate is cohesive, publish = false, and hidden behind facade-owned types.
  • Any release amalgamation is deterministic and verified from its packaged archive before adoption.
  • The final organization is selected from evidence and documented in ARCHITECTURE.md.

Decisions

  • This issue does not require a multi-crate workspace or an amalgamated release.
  • Public API stability is independent of physical crate boundaries.
  • No speculative kernal-api-data trait crate; introduce abstraction only for multiple real implementations or a demonstrated compilation boundary.
  • Start with feature-gated modules and split only where the measurements justify the maintenance cost.

Open questions

  • Which zccache, Soldr, and fbuild edit scenarios best represent daily incremental work?
  • Does a coarse split outperform a monolithic facade once Soldr/zccache cache reuse is included?

Related issues

Phase-0 measurement ownership for #5

This issue is the sole owner of the reproducible measurement protocol and recorded results used by #5's migration gate. The companion work must:

  • record the host, toolchain, Soldr/zccache versions, exact commands, feature sets, clean-state procedure, repeat count, and collection locations;
  • measure the current kernal-api baseline and the accepted minimal running-process substrate independently before feat(process): privately adapt the trimmed running-process substrate #6 adds the private adapter;
  • record resolved dependency graphs and prove disabled capabilities omit their trees;
  • measure the same clean and representative incremental zccache embedded workloads before/after each accepted migration slice, including elapsed critical path, peak compiler memory, and cache reuse;
  • link raw results to the feat: implement the kernal-api capability spine and fully rebase zccache embedded #5 capability inventory rather than redefine process, filesystem, IPC, or broker compatibility requirements here.

#5 owns compatibility inventory and behavior characterization; zackees/running-process#1143 owns substrate feature trimming. This separation prevents a duplicate Phase-0 issue while making the adapter's dependency and performance gate objective.

Activity

  1. changed the title [-]refactor: enforce platform and symbol leaves with single-crate amalgamation[/-] [+]perf: benchmark kernal-api compilation boundaries and release packaging[/+] on Aug 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions