aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-objdump/llvm-objdump.cpp
diff options
context:
space:
mode:
authorLouis Dionne <ldionne@apple.com>2020-02-10 18:30:43 +0100
committerLouis Dionne <ldionne@apple.com>2020-02-12 16:43:36 +0100
commit8bec8927134f116eb11ddea9db78b1a6241884c9 (patch)
treebc7d8965054b683ee396d5241cb092131794db47 /llvm/tools/llvm-objdump/llvm-objdump.cpp
parentfc8d033e966305ebed3ffcd7c633d6e9ebef10ae (diff)
downloadllvm-8bec8927134f116eb11ddea9db78b1a6241884c9.zip
llvm-8bec8927134f116eb11ddea9db78b1a6241884c9.tar.gz
llvm-8bec8927134f116eb11ddea9db78b1a6241884c9.tar.bz2
[libc++][Apple] Use CLOCK_MONOTONIC_RAW instead of CLOCK_UPTIME_RAW for steady_clock
Summary: In D27429, we switched the Apple implementation of steady_clock::now() from clock_gettime(CLOCK_MONOTONIC) to clock_gettime(CLOCK_UPTIME_RAW). The purpose was to get nanosecond precision, and also to improve the performance of the implementation. However, it appears that CLOCK_UPTIME_RAW does not satisfy the requirements of the Standard, since it is not strictly speaking monotonic. Indeed, the clock does not increment while the system is asleep, which had been mentioned in D27429 but somehow not addressed. This patch switches to CLOCK_MONOTONIC_RAW, which is monotonic, increased during sleep, and also has nanosecond precision. https://llvm.org/PR44773 Reviewers: bruno, howard.hinnant, EricWF Subscribers: christof, jkorous, dexonsmith, libcxx-commits, mclow.lists, EricWF Tags: #libc Differential Revision: https://reviews.llvm.org/D74341
Diffstat (limited to 'llvm/tools/llvm-objdump/llvm-objdump.cpp')
0 files changed, 0 insertions, 0 deletions