MCPcopy Create free account
hub / github.com/PlatformLab/NanoLog / toMicroseconds

Method toMicroseconds

runtime/Cycles.cc:160–164  ·  view source on GitHub ↗

* Given an elapsed time measured in cycles, return an integer * giving the corresponding time in microseconds. Note: toSeconds() * is faster than this method. * \param cycles * Difference between the results of two calls to rdtsc. * \param cyclesPerSec * Optional parameter to specify the frequency of the counter that #cycles * was taken from. Useful when converting a remote m

Source from the content-addressed store, hash-verified

158 * The time in microseconds corresponding to cycles (rounded).
159 */
160uint64_t
161Cycles::toMicroseconds(uint64_t cycles, double cyclesPerSec)
162{
163 return toNanoseconds(cycles, cyclesPerSec) / 1000;
164}
165
166/**
167 * Given an elapsed time measured in cycles, return an integer

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected