getSteadyTimestampNs#
Fully qualified name: carb::time::getSteadyTimestampNs
Defined in carb/time/Util.h
-
inline std::chrono::nanoseconds carb::time::getSteadyTimestampNs()#
Retrieves the current steady (monotonic) clock timestamp in nanoseconds.
Note
The values returned here may not include time while the system is suspended or hibernating. This behaviour is platform dependent however.
- Returns:
The elapsed time in nanoseconds since an arbitrary epoch (usually system boot). This will always be coming from the monotonic steady clock and will not be subject to NTP wallclock updates. Some platforms may however slightly adjust this clock by slowing it down or speeding it up as wall clock time updates arrive. It will still be guaranteed to be monotonically increasing however.