feat(mollusk): from_plan execution + cu-profiler-bench binary#10
Merged
Conversation
The detached cu-profiler-mollusk crate gains the executor the main CLI's `bench` delegates to: - `MolluskBackend::from_plan(plan, program_name)` parses a BenchPlan's base58/hex fixtures into solana Instruction/Account types and meters real compute units (fail-fast on malformed fixtures). - `run_plan(plan, program_name) -> Report` ties that through the core Profiler into a Mollusk-tagged report. - A thin Linux-only `cu-profiler-bench` binary (reads bench.toml, runs run_plan, renders the report). Kept a *separate* binary in the detached crate rather than a feature-gated CLI dependency, so the main CLI/core stay Solana-free and Windows- buildable (the project invariant). pure helpers (decode_hex, parse_pubkey) and an end-to-end demo test cover it. Verified by the Linux SBF CI job (the crate does not build on the local Windows gate). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces the (auto-closed, stacked) #9 with a clean branch off
main. Completes the turnkey real-CU path at the executor level.What
MolluskBackend::from_plan(plan, program_name)— parse aBenchPlan's base58/hex fixtures into SolanaInstruction/Accounttypes and meter real compute units.run_plan(plan, program_name) -> Report— plan → Mollusk-tagged report via the core Profiler.cu-profiler-benchbinary, which the main CLI'scu-profiler benchdelegates to overPATH.Invariant preserved
This is a separate binary in the detached
cu-profiler-molluskcrate, not a feature-gated dependency of the main CLI — so the core/CLI stay Solana-free and Windows-buildable. Only the detached crate links the Solana stack.Verification
Pure helpers (
decode_hex,parse_pubkey) and an end-to-end demo test (run_planmeters the demo.so) cover it. The crate does not build on the local Windows gate (which stays grade A, unaffected); the Linux SBF CI job verifies it.🤖 Generated with Claude Code