microsoft / microsoft/terminal
[Performance] Fast path for `RenderData::IsCursorDoubleWidth`
- Dominant language
- C++
- Stars
- 105k
- Forks
- 9.6k
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 29
Description
This is a sister issue of #10393.
Currently an unreasonable amount of CPU is wasted in checking `IsCursorDoubleWidth` in the buffer, due to the expensive construction of `TextBufferCellIterator`. I think it's fair to find a fast path for people who don't use width characters at all.

Contributor guide
Research direction
Start by locating RenderData::IsCursorDoubleWidth and the construction of TextBufferCellIterator mentioned in the issue. Trace how the buffer checks cursor width, then identify a fast path for users who do not use width characters. Done means the check avoids the expensive iterator construction in that case while preserving width-character behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- cli, desktop, performance
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100