-
Notifications
You must be signed in to change notification settings - Fork 47
perf(ice): zi ice tokenizing is 20% slower since #527 #554
Copy link
Copy link
Open
Labels
area:ziZi core behavior, APIs, or documentation.Zi core behavior, APIs, or documentation.performancePerformance-sensitive work or a measured regression in speed or memory.Performance-sensitive work or a measured regression in speed or memory.type:bugSomething is broken or behaving incorrectly.Something is broken or behaving incorrectly.
Description
Activity
Metadata
Metadata
Assignees
Labels
area:ziZi core behavior, APIs, or documentation.Zi core behavior, APIs, or documentation.performancePerformance-sensitive work or a measured regression in speed or memory.Performance-sensitive work or a measured regression in speed or memory.type:bugSomething is broken or behaving incorrectly.Something is broken or behaving incorrectly.
Type
Projects
- StatusShow more project fieldsTriage
Problem
An A/B on 2026-09-18 (fresh
zsh -fper sample, alternating order, 3 warmups, 30 samples) betweenmain56715fd(v2.1.0) andnextb4ab453shows one case outside noise: 200zi icecalls carrying 13 ices each take 151 ms onmainand 182 ms onnext, a +20.5% median regression, while every other case (source, light and tracked load, turbo queue plus burst, unload) is within ±1%. The change is #527:.zi-icenow consultsZI[nval-ice-list]and inspects the remainder for every matched word.Absolute cost is about 0.15 ms per
zi icecall, roughly +8 ms on a startup file with 50 ice calls, so this does not block the promotion; it is the kind of drift the benchmark suite (#553) exists to catch.Expected behavior
The common case (a valued ice, or a bare no-value ice) stays on the previous path; the extra check runs only when a matched no-value ice name has a non-empty remainder. Measure per-word cost with the benchmark's
icecase before and after.