diff options
author | Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com> | 2021-08-03 23:15:43 +0300 |
---|---|---|
committer | Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com) <spamtrap@nedprod.com> | 2021-08-03 23:15:43 +0300 |
commit | 8ead37a610a7f0424fccb1cca91f1ebeb55485a5 (patch) | |
tree | 8031da628782b60795d49e194e0978624fb0f357 /include/llfio/v2.0/detail/impl/posix/utils.ipp | |
parent | 5544436fd6654fcc6cd6b3a9c3f3b9b7e0b21865 (diff) |
Try fix last commit on Mac OS.
Diffstat (limited to 'include/llfio/v2.0/detail/impl/posix/utils.ipp')
-rw-r--r-- | include/llfio/v2.0/detail/impl/posix/utils.ipp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/llfio/v2.0/detail/impl/posix/utils.ipp b/include/llfio/v2.0/detail/impl/posix/utils.ipp index 1461ae8f..4a1649b7 100644 --- a/include/llfio/v2.0/detail/impl/posix/utils.ipp +++ b/include/llfio/v2.0/detail/impl/posix/utils.ipp @@ -1,5 +1,5 @@ /* Misc utilities -(C) 2016-2017 Niall Douglas <http://www.nedproductions.biz/> (6 commits) +(C) 2016-2021 Niall Douglas <http://www.nedproductions.biz/> (6 commits) File Created: Jan 2015 @@ -555,12 +555,12 @@ namespace utils ret.system_ns_in_kernel_mode += cpuInfo[CPU_STATE_MAX * n + CPU_STATE_SYSTEM]; ret.system_ns_in_idle_mode += cpuInfo[CPU_STATE_MAX * n + CPU_STATE_IDLE]; } - vm_deallocate(mach_task_self(), cpuInfo, sizeof(integer_t) * numCPUInfo); + vm_deallocate(mach_task_self(), cpuInfo, sizeof(integer_t) * numCpuInfo); static const double ts_multiplier = [] { mach_timebase_info_data_t timebase; mach_timebase_info(&timebase); return (double) timebase.numer / timebase.denom; - }; + }(); ret.system_ns_in_user_mode = (uint64_t)(ts_multiplier * ret.system_ns_in_user_mode); ret.system_ns_in_kernel_mode = (uint64_t)(ts_multiplier * ret.system_ns_in_kernel_mode); ret.system_ns_in_idle_mode = (uint64_t)(ts_multiplier * ret.system_ns_in_idle_mode); |