Select module files with ancestor boundary lookups

This commit is contained in:
2026-10-10 14:29:27 +00:00
parent 8552f92ddb
commit 8112a001d2
4 changed files with 56 additions and 6 deletions

View File

@@ -336,7 +336,15 @@ test-owned caches. This adds no live module-service completion gate.
## Issue 10: Remove the repeated boundary scan from file selection (P2)
Status: open. Category: code quality and avoidable computational cost.
Status: complete. Category: code quality and avoidable computational cost.
**Completion:** File selection indexes boundary directories and looks up each
entry's ancestors. Existing ordering, vendor/shared selection, full reference
lookup, and reader/cache behavior pass the complete offline validation suite.
A component benchmark retains 20,000 inputs with 0, 1,000, and 4,000 boundaries.
On this host, the 4,000-boundary case decreased from about 2.73 seconds to 38
milliseconds per selection; the new cases ranged from 29 to 38 milliseconds.
These are illustrative measurements without timing gates or input limits.
**Evidence:** [`selectInputEntries`](../../internal/validation/tree.go) loops
over all nested-module boundaries for every candidate entry. This costs