> -----Original Message-----
> [mailto:[EMAIL PROTECTED] On Behalf 
> Of Tom Lane
> Sent: 07 March 2005 22:57
> To: John A Meinel
> Cc: Dave Held; pgsql-performance@postgresql.org; 
> Subject: Re: [pgsql-hackers-win32] [PERFORM] Help with tuning 
> this query (with 
> Which brings up a question: just what does QueryPerformanceCounter
> measure?

inui/windowsuserinterface/windowing/timers/abouttimers.asp says:

If a high-resolution performance counter exists on the system, you can
use the QueryPerformanceFrequency function to express the frequency, in
counts per second. The value of the count is processor dependent. On
some processors, for example, the count might be the cycle rate of the
processor clock.

The QueryPerformanceCounter function retrieves the current value of the
high-resolution performance counter. By calling this function at the
beginning and end of a section of code, an application essentially uses
the counter as a high-resolution timer. For example, suppose that
QueryPerformanceFrequency indicates that the frequency of the
high-resolution performance counter is 50,000 counts per second. If the
application calls QueryPerformanceCounter immediately before and
immediately after the section of code to be timed, the counter values
might be 1500 counts and 3500 counts, respectively. These values would
indicate that .04 seconds (2000 counts) elapsed while the code executed.

Regards, Dave.

---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

Reply via email to