Avatar for the astral-sh user
astral-sh
ruff
BlogDocsChangelog

Approximate token vec size to reduce regrows

#25354
Comparing
micha/view-benchmark-token-capacity
(
e02394f
) with
main
(
4b18e1f
)
CodSpeed Performance Gauge
-1%
Improvement
3
Regression
4
Untouched
116

Benchmarks

123 total
parser[numpy/globals.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
-11%
19.7 KB22.1 KB
linter/default-rules[pydantic/types.py]
crates/ruff_benchmark/benches/linter.rs::default_rules::benchmark_default_rules
CodSpeed Performance Gauge
-8%
348.7 KB380.1 KB
parser[unicode/pypinyin.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
-6%
58.7 KB62.2 KB
parser[unicode/pypinyin.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
-4%
250.2 µs260.9 µs
parser[numpy/ctypeslib.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
+9%
200.6 KB183.3 KB
parser[numpy/ctypeslib.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
+9%
710.1 µs654.1 µs
parser[large/dataset.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
+5%
912.2 KB870.2 KB
parser[large/dataset.py]
crates/ruff_benchmark/benches/parser.rs::parser::benchmark_parser
CodSpeed Performance Gauge
+4%
3.6 ms3.5 ms
ty_check_file[incremental]
crates/ruff_benchmark/benches/ty.rs::check_file::benchmark_incremental
CodSpeed Performance Gauge
+4%
165.6 KB159.7 KB
hydra-zen
crates/ruff_benchmark/benches/ty.rs::project::hydra::project
CodSpeed Performance Gauge
+2%
72.4 MB70.9 MB
ty_micro[pandas_tdd]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_pandas_tdd
CodSpeed Performance Gauge
+2%
46.9 MB45.9 MB
ty_micro[vararg_parameter_type_accumulation]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_vararg_parameter_type_accumulation
CodSpeed Performance Gauge
+2%
13.8 MB13.6 MB
ty_micro[very_large_tuple]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_very_large_tuple
CodSpeed Performance Gauge
+2%
15.8 MB15.6 MB
ty_micro[literal_match_fallthrough]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_literal_match_fallthrough
CodSpeed Performance Gauge
+2%
14.2 MB14 MB
ty_micro[many_enum_members]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_many_enum_members
CodSpeed Performance Gauge
+2%
18.5 MB18.2 MB
ty_micro[gradual_vararg_call]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_gradual_vararg_call
CodSpeed Performance Gauge
+2%
15.6 MB15.4 MB
ty_micro[many_tuple_assignments]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_many_tuple_assignments
CodSpeed Performance Gauge
+2%
63.3 ms62.3 ms
ty_micro[many_tuple_assignments]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_many_tuple_assignments
CodSpeed Performance Gauge
+2%
14.8 MB14.6 MB
ty_micro[typevar_mapping_small_accumulations]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_typevar_mapping_small_accumulations
CodSpeed Performance Gauge
+1%
15.9 MB15.6 MB
ty_micro[complex_constrained_attributes_2]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_complex_constrained_attributes_2
CodSpeed Performance Gauge
+1%
16.1 MB15.8 MB
ty_micro[complex_constrained_attributes_1]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_complex_constrained_attributes_1
CodSpeed Performance Gauge
+1%
16.1 MB15.8 MB
ty_micro[many_tuple_assignments]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_tuple_implicit_instance_attributes
CodSpeed Performance Gauge
+1%
16.2 MB16 MB
ty_check_file[cold]
crates/ruff_benchmark/benches/ty.rs::check_file::benchmark_cold
CodSpeed Performance Gauge
+1%
22.7 MB22.4 MB
ty_micro[large_isinstance_narrowing]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_large_isinstance_narrowing
CodSpeed Performance Gauge
+1%
17.1 MB16.9 MB
ty_micro[many_string_assignments]
crates/ruff_benchmark/benches/ty.rs::micro::benchmark_many_string_assignments
CodSpeed Performance Gauge
+1%
17.1 MB16.9 MB

Commits

Click on a commit to change the comparison range
Base
main
4b18e1f
-4.88%
Use estimated capacity for parser token source
64da820
1 day ago
by MichaReiser
+3.7%
Shrink token buffer after parsing
a753042
1 day ago
by MichaReiser
-4.22%
Use conservative token capacity estimate
8498ba1
1 day ago
by MichaReiser
-0.32%
Change to 10%
464473c
1 day ago
by MichaReiser
+4.54%
Go up to 15% again
e02394f
6 hours ago
by MichaReiser
© 2026 CodSpeed Technology
Home Terms Privacy Docs