end;
+function curTimeMicro (): UInt64; inline;
+function curTimeMilli (): UInt64; inline;
+
+
implementation
{$IF DEFINED(LINUX)}
var
r: THPTimeType;
begin
- if (mFrequency = 0) then initTimerIntr();
+ //if (mFrequency = 0) then initTimerIntr();
{$IF DEFINED(LINUX)}
clock_gettime(CLOCK_MONOTONIC, @r);
result := UInt64(r.tv_sec)*1000000+UInt64(r.tv_nsec) div 1000; // microseconds
end;
+function curTimeMilli (): UInt64; inline;
+begin
+ result := curTimeMicro div 1000;
+end;
+
+
// ////////////////////////////////////////////////////////////////////////// //
class function TStopWatch.Create (): TStopWatch;
begin
end;
+begin
+ initTimerIntr();
end.