extraction_is_linear's 4s budget is not "one to two orders of magnitude" above the cost — one_line shapes sit AT the ceiling and flake #163
Labels
No labels
code-review
correctness
dos
performance
security
severity/high
severity/low
severity/medium
tech-debt
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
h-dv/code-index#163
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Windows CI failed at
ea821b6:This is not a regression.
crates/plugins/src/typescript.rshas not changed on master since8210c24(the tree-sitter upgrade), and the resolver lane's #125 edits to it are uncommitted and were not in the tree CI built.The budget's own justification is false for this shape
crates/plugins/src/lib.rs:152-155says:Measured on Linux by temporarily lowering
BUDGETso the assertion reports the real duration for every cell:Seventeen of twenty-one cells are genuinely loose — 20 ms to 872 ms against a 4 s ceiling is the one-to-two orders the doc promises. The four
one_linecells are not, and two of them sit at or over the ceiling.So the shape that fails is the one whose margin was never checked against the doc's own claim. The gate is not catching a quadratic here; it is reporting that a linear cost is close to a ceiling nobody measured.
Caveat, stated because it changes what may be concluded
The measurements above were taken on a box under load ~34 (five build lanes). They are contended and are NOT a clean baseline. What they establish is the ORDER:
one_linecosts seconds, not milliseconds, so the doc's claim is wrong by two orders of magnitude regardless of contention. An isolated re-measure is still owed before any new number is written down.What the repair should be
Not simply raising the number. A wall-clock ceiling on a shared CI box is the thing #126 was filed about, and this project has already twice chosen a load-independent measure over a wall-clock one and said why:
idle_worker_footprintmeasures PSS, "so it is immune to the contention that makes a wall-clock assertion flaky";corpus_costcounts SQLitevm_stepinstead of time.The property under test is "the cost of one construct must not depend on how many precede it" — a shape claim, not a speed claim. It is better served by a ratio than by an absolute:
csharp_monorepo_stages_do_not_scale_quadraticallyalready uses for the resolver), orEither catches a quadratic by construction and cannot flake on a loaded box. If an absolute ceiling is kept, the doc must be corrected — a justification that is false for the cells that actually fail is worse than none, because it tells the next reader not to look.
Related
🤖 Generated with Claude Code
https://claude.ai/code/session_01K1zj5VcFJvJt3pQxe9259K