edee1335c14855373cfc617b2f2211de309bac79
Test scenario is `cat`ing the public domain wiki text data from http://cs.fit.edu/~mmahoney/compression/enwik8.zip in the terminal; that file is 96M in size. `time cat ~/Downloads/enwik8.wiki` Prior to this change, depending on the OS, the time to cat the file could be several minutes. Digging in, the bottleneck appears to be that there isn't sufficient parallelism between the reader and the parser, which means that the rate of reading data is constrained by how long it takes to parse and render a frame. This commit switches away from using a synchronized vecdeque to effectively create a non-blocking pipe, to "simply" using a socketpair with a larger buffer size. We now do blocking pty read -> write to socketpair in the reader thread, and then read socketpair -> parse in the other. The key difference between before and after being that the pty read can continue to read and accumulate data (with an upper bound, so that CTRL-C is still responsive) while we're parsing and rendering a frame. This increases the throughput for this scenario, bringing it down from ~3:30 to ~17 seconds on this Ryzen 2700X system. refs: https://github.com/wez/wezterm/issues/927
Wez's Terminal
A GPU-accelerated cross-platform terminal emulator and multiplexer written by @wez and implemented in Rust
User facing docs and guide at: https://wezfurlong.org/wezterm/
Screenshot of wezterm on macOS, running vim
Installation
https://wezfurlong.org/wezterm/installation.html
Getting help
This is a spare time project, so please bear with me. There are a couple of channels for support:
- You can use the GitHub issue tracker to see if someone else has a similar issue, or to file a new one.
- Start or join a thread in our GitHub Discussions; if you have general questions or want to chat with other wezterm users, you're welcome here!
- There is a Matrix room via Element.io for (potentially!) real time discussions.
The GitHub Discussions and Element/Gitter rooms are better suited for questions than bug reports, but don't be afraid to use whichever you are most comfortable using and we'll work it out.
Description
The agentic terminal: a WezTerm fork with LLeMbas built in
316 MiB
0 Stars
2 Watchers
0 Forks
Languages
Rust
97.7%
Python
1%
Shell
0.9%
Nix
0.2%
