Avatar for the jquast user
jquast
wcwidth
BlogDocsChangelog

improve width() performance

#181Merged
Comparing
jq/width-improvement
(
85e8957
) with
master
(
7a398cb
)
CodSpeed Performance Gauge
+59%
Improvement
5
Untouched
30
Archived
3

Benchmarks

38 total
test_center_ascii
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
28.7 µs28.7 µs
test_wcswidth_short_mixed
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
34.5 µs34.4 µs
test_wrap_long_text
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
4.3 ms4.3 ms
test_wcswidth_long_japanese
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
279.2 µs278.6 µs
test_wrap_short_ascii
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
349.5 µs348.8 µs
test_clip_with_ansi
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
105.6 µs105.8 µs
test_iter_graphemes_ascii
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
117.5 µs117.3 µs
test_ljust_japanese
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
43.7 µs43.7 µs
test_ljust_ascii
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
27.6 µs27.6 µs
test_rjust_ascii
tests/test_benchmarks.py
CodSpeed Performance Gauge
0%
27.6 µs27.6 µs
test_center_udhr_lines
tests/test_benchmarks.py
Archived
CodSpeed Performance Gauge
+36%
2.5 ms1.9 ms
test_wcswidth_udhr
tests/test_benchmarks.py
Archived
CodSpeed Performance Gauge
+1%
25.4 µs25.1 µs
test_rjust_udhr_lines
tests/test_benchmarks.py
Archived
CodSpeed Performance Gauge
+38%
2.4 ms1.8 ms

Commits

Click on a commit to change the comparison range
Base
master
7a398cb
-23.3%
Merge remote-tracking branch 'origin/master' into jq/width-improvement
5f55f28
5 months ago
by jquast
0%
better document "glitch emoji" test measurements
627a93d
5 months ago
by jquast
+81.93%
try something of a compromise, long v. short strings
b3f5a3e
5 months ago
by jquast
0%
make tests match our un-expectations
332c4e5
5 months ago
by jquast
0%
provide full branch coverage
85e8957
5 months ago
by jquast
© 2026 CodSpeed Technology
Home Terms Privacy Docs