diff options
author | Luke Groeninger <luke@dghost.net> | 2021-01-02 00:45:53 -0600 |
---|---|---|
committer | cgzones <cgzones@googlemail.com> | 2021-01-02 22:33:20 +0100 |
commit | a150a81669027601aefc231f208a715e16b24c62 (patch) | |
tree | 66047479f628691cd3369b3a53025893a5193553 /darwin/DarwinProcessList.c | |
parent | 90ea3ac3c9104d1519e067aeeefc07c7f75313ca (diff) |
Fix CPU percentage on M1 silicon Macs
Diffstat (limited to 'darwin/DarwinProcessList.c')
-rw-r--r-- | darwin/DarwinProcessList.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/darwin/DarwinProcessList.c b/darwin/DarwinProcessList.c index a2848920..e2e98ce6 100644 --- a/darwin/DarwinProcessList.c +++ b/darwin/DarwinProcessList.c @@ -161,7 +161,7 @@ void ProcessList_delete(ProcessList* this) { static double ticksToNanoseconds(const double ticks) { const double nanos_per_sec = 1e9; - return ticks / (double) Platform_clockTicksPerSec * Platform_timebaseToNS * nanos_per_sec; + return (ticks / Platform_timebaseToNS) * (nanos_per_sec / (double) Platform_clockTicksPerSec); } void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate) { |