23 lines
992 B
Diff
23 lines
992 B
Diff
Use monotonic clock for pthread_cond_timedwait with musl too.
|
|
|
|
--- a/src/3rdparty/chromium/v8/src/base/platform/condition-variable.cc
|
|
+++ b/src/3rdparty/chromium/v8/src/base/platform/condition-variable.cc
|
|
@@ -20,7 +20,7 @@ namespace base {
|
|
|
|
ConditionVariable::ConditionVariable() {
|
|
#if (V8_OS_FREEBSD || V8_OS_NETBSD || V8_OS_OPENBSD || \
|
|
- (V8_OS_LINUX && V8_LIBC_GLIBC))
|
|
+ V8_OS_LINUX)
|
|
// On Free/Net/OpenBSD and Linux with glibc we can change the time
|
|
// source for pthread_cond_timedwait() to use the monotonic clock.
|
|
pthread_condattr_t attr;
|
|
@@ -96,7 +96,7 @@ bool ConditionVariable::WaitFor(Mutex* m
|
|
&native_handle_, &mutex->native_handle(), &ts);
|
|
#else
|
|
#if (V8_OS_FREEBSD || V8_OS_NETBSD || V8_OS_OPENBSD || \
|
|
- (V8_OS_LINUX && V8_LIBC_GLIBC))
|
|
+ V8_OS_LINUX)
|
|
// On Free/Net/OpenBSD and Linux with glibc we can change the time
|
|
// source for pthread_cond_timedwait() to use the monotonic clock.
|
|
result = clock_gettime(CLOCK_MONOTONIC, &ts);
|