Must return ticks per second as on Windows, because caller might perform own conversion of native value.
I think I have fixed that, but I am not sure any more. Could someone check:
switch (performance_counter::check_rtc_availability()) { case has_rtc_type::yes: // clock_gettime returns nanoseconds. performance_counter::frequencyValue = performance_counter::nanoseconds_per_second; break; case has_rtc_type::no: // gettimeofday returns microseconds. performance_counter::frequencyValue = performance_counter::microseconds_per_second; break; default: // This should be unreachable. THE_ASSERT(false); break; }
Log in to post a comment.
I think I have fixed that, but I am not sure any more. Could someone check: