HomePhabricator

[Chrono][Darwin] Make steady_clock use CLOCK_UPTIME_RAW

Description

[Chrono][Darwin] Make steady_clock use CLOCK_UPTIME_RAW

Use CLOCK_UPTIME_RAW in case clock_gettime is available on Darwin.

On Apple platforms only CLOCK_UPTIME_RAW or mach_absolute_time are able
to time functions in the nanosecond range. Thus, they are the only
acceptable implementations of steady_clock.

Differential Revision: https://reviews.llvm.org/D27429

rdar://problem/29449467

Details

Committed
brunoJan 9 2017, 11:21 AM
Differential Revision
D27429: [Chrono][Darwin] On Darwin use CLOCK_UPTIME_RAW instead of CLOCK_MONOTONIC
Branches
Unknown
Tags
Unknown