C# Class NetMQ.Core.Utils.Clock

The Clock class provides properties for getting timer-counts in either milliseconds or microseconds, and the CPU's timestamp-counter if available.
Show file Open project: somdoron/netmq

Public Methods

Method Description
NowMs ( ) : long

Return the Low-Precision timestamp, as a 64-bit integer denoting milliseconds. In tight loops generating it can be 10 to 100 times faster than the High-Precision timestamp.

NowUs ( ) : long

Return the High-Precision timestamp, as a 64-bit integer that denotes microseconds.

Rdtsc ( ) : long

Return the CPU's timestamp counter, or 0 if it's not available.

Private Methods

Method Description
Clock ( ) : System

Method Details

NowMs() public static method

Return the Low-Precision timestamp, as a 64-bit integer denoting milliseconds. In tight loops generating it can be 10 to 100 times faster than the High-Precision timestamp.
public static NowMs ( ) : long
return long

NowUs() public static method

Return the High-Precision timestamp, as a 64-bit integer that denotes microseconds.
public static NowUs ( ) : long
return long

Rdtsc() public static method

Return the CPU's timestamp counter, or 0 if it's not available.
public static Rdtsc ( ) : long
return long