aboutsummaryrefslogtreecommitdiffstats
path: root/util/system/hp_timer.h
diff options
context:
space:
mode:
authoryazevnul <yazevnul@yandex-team.ru>2022-02-10 16:46:46 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:46:46 +0300
commit8cbc307de0221f84c80c42dcbe07d40727537e2c (patch)
tree625d5a673015d1df891e051033e9fcde5c7be4e5 /util/system/hp_timer.h
parent30d1ef3941e0dc835be7609de5ebee66958f215a (diff)
downloadydb-8cbc307de0221f84c80c42dcbe07d40727537e2c.tar.gz
Restoring authorship annotation for <yazevnul@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'util/system/hp_timer.h')
-rw-r--r--util/system/hp_timer.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/util/system/hp_timer.h b/util/system/hp_timer.h
index 0a4c252ec2..ea02b660ed 100644
--- a/util/system/hp_timer.h
+++ b/util/system/hp_timer.h
@@ -5,29 +5,29 @@
namespace NHPTimer {
using STime = i64;
// May delay for ~50ms to compute frequency
- double GetSeconds(const STime& a) noexcept;
+ double GetSeconds(const STime& a) noexcept;
// Returns the current time
- void GetTime(STime* pTime) noexcept;
+ void GetTime(STime* pTime) noexcept;
// Returns the time passed since *pTime, and writes the current time into *pTime.
- double GetTimePassed(STime* pTime) noexcept;
+ double GetTimePassed(STime* pTime) noexcept;
// Get TSC frequency, may delay for ~50ms to compute frequency
- double GetClockRate() noexcept;
- // same as GetClockRate, but in integer
- ui64 GetCyclesPerSecond() noexcept;
+ double GetClockRate() noexcept;
+ // same as GetClockRate, but in integer
+ ui64 GetCyclesPerSecond() noexcept;
}
struct THPTimer {
THPTimer() noexcept {
Reset();
}
- void Reset() noexcept {
+ void Reset() noexcept {
NHPTimer::GetTime(&Start);
}
- double Passed() const noexcept {
+ double Passed() const noexcept {
NHPTimer::STime tmp = Start;
return NHPTimer::GetTimePassed(&tmp);
}
- double PassedReset() noexcept {
+ double PassedReset() noexcept {
return NHPTimer::GetTimePassed(&Start);
}