microsoft/Terminal
Auf GitHub ansehen[Performance] Replace std::vector with more lightweight structure in `RenderData::GetPatternId`
Open
#10.564 geöffnet am 6. Juli 2021
Area-PerformanceArea-RenderingHelp WantedIssue-TaskProduct-Meta
Repository-Metriken
- Stars
- (35.764 Stars)
- PR-Merge-Metriken
- (Durchschn. Merge 27T 19h) (24 gemergte PRs in 30 T)
Beschreibung
This is about the scrolling test in #10563. A simplified repro would be:
time bash -c 'yes | head -n1000000'
which takes 7-8s with windows terminal and 300ms with gnome terminal.
Test case provided by @lhecker.
These lines show up in the hot paths of the trace of OpenConsole:
https://github.com/microsoft/terminal/blob/main/src/renderer/base/renderer.cpp#L788

It appears that simply constructing empty std::vector (empty because this is in conhost/OpenConsole) is quite expensive.
CC @PankajBhojwani