diff options
author | Christian Duerr <contact@christianduerr.com> | 2021-07-03 20:31:50 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-03 20:31:50 +0000 |
commit | c6ed855bfa036ffe5e3e3ea12819db6a1a25d4e1 (patch) | |
tree | 32e97cf1b3c20c107e1b78a1e49f92d86d9b9b15 /CHANGELOG.md | |
parent | 4dd70ba3a155d1eebe38bcd5a5c4c03ca09f2fea (diff) | |
download | alacritty-c6ed855bfa036ffe5e3e3ea12819db6a1a25d4e1.tar.gz alacritty-c6ed855bfa036ffe5e3e3ea12819db6a1a25d4e1.zip |
Add buffer for PTY reads during terminal lock
Before this patch, Alacritty's PTY reader would always try to read the
PTY into a buffer and then wait for the acquisition of the terminal lock
to process this data. Since locking for the terminal could take some
time, the PTY could fill up with the thread idling while doing so.
As a solution, this patch keeps reading to a buffer while the terminal
is locked in the renderer and starts processing all buffered data as
soon as the lock is released.
This has halfed the runtime of a simple `cat` benchmark from ~9 to ~4
seconds when the font size is set to `1`. Running this patch with
"normal" grid densities does not appear to make any significant
performance differences in either direction.
One possible memory optimization for the future would be to use this
buffer for synchronized updates, but since this currently uses a dynamic
buffer and would be a bit more cluttered, it has not been implemented in
this patch.
Diffstat (limited to 'CHANGELOG.md')
-rw-r--r-- | CHANGELOG.md | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 373530ff..ee999003 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -17,6 +17,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - Regression in rendering performance with dense grids since 0.6.0 - Crash/Freezes with partially visible fullwidth characters due to alt screen resize - Incorrect vi cursor position after invoking `ScrollPageHalfUp` action +- Slow PTY read performance with extremely dense grids ## 0.8.0 |