[WTF] Move currentCPUTime and sleep(Seconds) to CPUTime.h and Seconds.h respectively
Created attachment 334954 [details] Patch
Created attachment 334956 [details] Patch
Created attachment 334960 [details] Patch
Created attachment 334976 [details] Patch
Comment on attachment 334976 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=334976&action=review r=me > Source/WTF/ChangeLog:16 > + conslidate various time-source implementations in one place. *consolidate*
Comment on attachment 334976 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=334976&action=review >> Source/WTF/ChangeLog:16 >> + conslidate various time-source implementations in one place. > > *consolidate* Thanks, fixed.
Created attachment 334985 [details] Patch
Comment on attachment 334985 [details] Patch Let's go.
Comment on attachment 334985 [details] Patch Clearing flags on attachment: 334985 Committed r229209: <https://trac.webkit.org/changeset/229209>
Comment on attachment 334985 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=334985&action=review > Source/WTF/wtf/cocoa/CPUTimeCocoa.mm:79 > + thread_info(threadPort, THREAD_BASIC_INFO, reinterpret_cast<thread_info_t>(&info), &infoCount); RELEASE_ASSERT that it returns KERN_SUCCESS. > Source/WTF/wtf/unix/CPUTimeUnix.cpp:50 > + clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts); Release assert that it returns 0. > Source/WTF/wtf/win/CPUTimeWin.cpp:68 > + ASSERT_UNUSED(ret, ret); Release assert that it's non-zero.
Comment on attachment 334985 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=334985&action=review Thank you! >> Source/WTF/wtf/cocoa/CPUTimeCocoa.mm:79 >> + thread_info(threadPort, THREAD_BASIC_INFO, reinterpret_cast<thread_info_t>(&info), &infoCount); > > RELEASE_ASSERT that it returns KERN_SUCCESS. Nice, I'll fix in a follow-up patch. >> Source/WTF/wtf/unix/CPUTimeUnix.cpp:50 >> + clock_gettime(CLOCK_THREAD_CPUTIME_ID, &ts); > > Release assert that it returns 0. Nice, fixed. >> Source/WTF/wtf/win/CPUTimeWin.cpp:68 >> + ASSERT_UNUSED(ret, ret); > > Release assert that it's non-zero. Fixed.
Committed r229289: <https://trac.webkit.org/changeset/229289>
<rdar://problem/38146407>
Committed r229571: <https://trac.webkit.org/changeset/229571>