xterm.js: Render performance degradation from 3.0.2 to 3.7.0
Update: This issue should be introduced between 3.3.0 and 3.4.0.
Originally reported at: https://github.com/tsl0922/ttyd/issues/126
Details
- Browser and browser version: Chrome69.0.3497.81
- OS version: macOS High Sierra 10.13.6
- xterm.js version: 3.7.0
Steps to reproduce
- Start the 3.7.0 demo.
- Open the demo with chrome, and turn on the FPS meter.
- Resize it to a larger size (155 cols / 40 rows).
- Run:
vtop
(npm install -g vtop
). - Press and hold the down arrow button.
- Result: 4-14 PFS on 3.7.0 (not stable) and 30-35 FPS on 3.3.0 (stable).
It’s much smoother on 3.0.2 (ttyd 1.4.0) than 3.7.0 (ttyd 1.4.1).
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 20 (20 by maintainers)
I think I fixed it, I removed a bunch of the object/string overhead and drawing from an ImageBitmap seems to make the dynamic cache go down to around 3ms on average (from 7). PR probably tomorrow.