You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
#205 follow-up: wire library-selection cache into orchestrators (teensy, stm32) #214
Phase 4 of #205 (PR #212) shipped the resolve_cached(...) helper in crates/fbuild-library-select/src/cache.rs with a zccache_artifact::KvStore backend and 7 cache tests. The helper is correct in isolation but no production code calls it — framework_libs::resolve_framework_library_sources (the orchestrator entry point) still calls the uncached resolve(...).
Result: every build re-runs the LDF walk from scratch even though the resolver output is a pure function and the cache infrastructure is in place. This is the prerequisite for Phase 7 warm-cache benches (bench/fastled-examples) — there is no warm path to measure today.
Scope
Add a cached entry point in crates/fbuild-build/src/framework_libs.rs (e.g. resolve_framework_library_sources_cached) that takes the same (libraries, project_dir, src_dir) plus CacheKeyInputs and a KvStore.
Open a process-shared KvStore rooted at ~/.fbuild/cache/library-selection/ (or the daemon equivalent under dev/prod paths via fbuild-paths).
Update crates/fbuild-build/src/teensy/orchestrator.rs:163 and crates/fbuild-build/src/stm32/orchestrator.rs:114 to call the cached variant. Construct CacheKeyInputs from the orchestrator's Framework (install path, version) and the platform's compiler triple.
Refresh docs/architecture/library-selection.md status block (Phase 4 has shipped; the gating note pointing at zccache#130 is stale).
Add a test in framework_libs.rs that round-trips through the cached variant and asserts a second call hits.
Out of scope
ESP32 / AVR orchestrators — they don't call resolve_framework_library_sources today; tracked separately if needed.
Cache eviction / LRU — zccache_artifact::KvStore handles its own retention.
Phase 7 warm bench harness (separate follow-up).
Acceptance
All existing 16 library-select tests + 4 framework_libs tests still pass.
New cache-hit test passes.
cargo doc --no-deps -p fbuild-build clean.
Workspace clippy -D warnings clean.
Refs: #205 Phase 7 prep; closes Phase 4 production wiring.
Activity
feat(library-selection): #214 wire resolve_cached into teensy + stm32…
fix(acceptance): #223 stm32 SPI + teensyLC LTO-symbol probes
fix(acceptance): #223 stm32 SPI + teensyLC LTO-symbol probes (#226)