Muffle updates to the cursor position to 1/~100ms#5289
Conversation
This stops us from dispatching back-to-back terminal cursor position updates to the TSF control before it has a chance to get back to us. Fixes #5288.
|
I still wanted it to be named "tuned mass damper" but fine. Let's do this. |
leonMSFT
left a comment
There was a problem hiding this comment.
Thanks for doing this 😅
|
We still dispatch about 60 of them printing the entire 6MB file, but that's a 100000000000000000% reduction and the UI remains fully responsive. |
|
Alright, i switched this from a mutex to an atomic -- it's cheaper and the platform cannot deny us. I also took some measurements. For a .070-second run of trace logging from that 6MB file: We tried to notify TSF 19798 times, and we successfully notified it 14 times. We can probably do better than "notify 14 times in 7 hundredths of a second" |
|
After damping, i got it down to 502 cursor updates for the entire file print. |
e8f95d2 to
93a2995
Compare
leonMSFT
left a comment
There was a problem hiding this comment.
Makes sense to me, seems to muffle harder
|
Hey I'm just seeing this now in the morning, but @greg904 had a great little throttle helper over in |
This stops us from dispatching back-to-back terminal cursor position
updates to the TSF control before it has a chance to get back to us.
Fixes #5288
This was tested live with the 6MB repro file from "Terminal Not Speed Enough".