-
Notifications
You must be signed in to change notification settings - Fork 27
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: performance issue caused by the render calls
mactop has high CPU usage. Running it with cpuprofiling shows that the top CPU time is spent in the termui.Render calls (to be specific, in the ioctl syscalls there). I removed a bunch of unnecessary Render calls (there were some duplicates) and replaced all the other calls with a throttled version: I call Render in the main process but not more often than twice in the single "update interval" period. This should address issue #13.
- Loading branch information
Showing
1 changed file
with
35 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters