summaryrefslogtreecommitdiffstats
path: root/botan/src/timer/win32_query_perf_ctr/tm_win32.cpp
blob: 6b878e6e22ac04eadc77858c11a609a42b894da0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/*
* Win32 Timer
* (C) 1999-2007 Jack Lloyd
*
* Distributed under the terms of the Botan license
*/

#include <botan/tm_win32.h>
#include <windows.h>

namespace Botan {

/*
* Get the timestamp
*/
u64bit Win32_Timer::clock() const
   {
   LARGE_INTEGER tv;
   ::QueryPerformanceCounter(&tv);
   return tv.QuadPart;
   }

}