ice_fire333
驱动老牛
驱动老牛
  • 注册日期2002-10-08
  • 最后登录2007-08-13
  • 粉丝0
  • 关注0
  • 积分31分
  • 威望4点
  • 贡献值0点
  • 好评度1点
  • 原创分0分
  • 专家分0分
阅读:1623回复:7

解释一下,很简单

楼主#
更多 发布于:2002-11-26 17:27
KeQueryPerformanceCounter
win2k ddk中,帮忙解释一下,正确马上给分。
赵客缦胡缨,吴钩霜雪明。银鞍照白马,飒沓如流星。   十步杀一人,千里不留行。事了拂衣去,深藏身与名。   闲过信陵饮,脱剑膝前横。将炙啖朱亥,持觞劝侯嬴。   三杯吐然诺,五岳倒为轻。眼花耳热后,意气素霓生。   救赵挥金槌,邯郸先震惊。千秋二壮士,煊赫大梁城。   纵死侠骨香,不惭世上英。谁能书阁下。白首太玄经。
cicada
驱动小牛
驱动小牛
  • 注册日期2003-12-09
  • 最后登录2008-07-11
  • 粉丝1
  • 关注0
  • 积分74分
  • 威望15点
  • 贡献值0点
  • 好评度7点
  • 原创分0分
  • 专家分0分
沙发#
发布于:2004-10-28 20:34
我也顶!
ice_fire333
驱动老牛
驱动老牛
  • 注册日期2002-10-08
  • 最后登录2007-08-13
  • 粉丝0
  • 关注0
  • 积分31分
  • 威望4点
  • 贡献值0点
  • 好评度1点
  • 原创分0分
  • 专家分0分
板凳#
发布于:2002-12-04 16:50
我顶
赵客缦胡缨,吴钩霜雪明。银鞍照白马,飒沓如流星。   十步杀一人,千里不留行。事了拂衣去,深藏身与名。   闲过信陵饮,脱剑膝前横。将炙啖朱亥,持觞劝侯嬴。   三杯吐然诺,五岳倒为轻。眼花耳热后,意气素霓生。   救赵挥金槌,邯郸先震惊。千秋二壮士,煊赫大梁城。   纵死侠骨香,不惭世上英。谁能书阁下。白首太玄经。
ice_fire333
驱动老牛
驱动老牛
  • 注册日期2002-10-08
  • 最后登录2007-08-13
  • 粉丝0
  • 关注0
  • 积分31分
  • 威望4点
  • 贡献值0点
  • 好评度1点
  • 原创分0分
  • 专家分0分
地板#
发布于:2002-11-28 11:44
获取性能计数器的当前值. WINNT在一定时间间隔就会更新计数器. 时间间隔大小,通过提供PerformanceFrequency的存储空间, 让函数填写.PerformanceFrequency中将返回2百万,那么更新频率就是2百万分之1秒更新一次此计数器.

我是想知道这个计数器是什么东东,系统用它通常来做什么?返回值受什么因素影响?
赵客缦胡缨,吴钩霜雪明。银鞍照白马,飒沓如流星。   十步杀一人,千里不留行。事了拂衣去,深藏身与名。   闲过信陵饮,脱剑膝前横。将炙啖朱亥,持觞劝侯嬴。   三杯吐然诺,五岳倒为轻。眼花耳热后,意气素霓生。   救赵挥金槌,邯郸先震惊。千秋二壮士,煊赫大梁城。   纵死侠骨香,不惭世上英。谁能书阁下。白首太玄经。
jansen
驱动小牛
驱动小牛
  • 注册日期2001-10-21
  • 最后登录2007-10-17
  • 粉丝0
  • 关注0
  • 积分0分
  • 威望0点
  • 贡献值0点
  • 好评度0点
  • 原创分0分
  • 专家分0分
地下室#
发布于:2002-11-27 19:41
KeQueryPerformanceCounter返回一个从系统启动以来的一个64位滴答(系统中非常小的时间单位)数目值.它用来反应系统的性能的度量.
正如楼上的解释返回值是2000000时,那么刷新就是1/2000000的时间间隔增加计数器,不要频繁的调用该例程会降低系统的I/O性能
rich
lu0
lu0
论坛版主
论坛版主
  • 注册日期2001-06-10
  • 最后登录2016-04-05
  • 粉丝2
  • 关注0
  • 积分-6311分
  • 威望21111点
  • 贡献值0点
  • 好评度7点
  • 原创分0分
  • 专家分0分
5楼#
发布于:2002-11-27 14:43
获取性能计数器的当前值. WINNT在一定时间间隔就会更新计数器. 时间间隔大小,通过提供PerformanceFrequency的存储空间, 让函数填写.PerformanceFrequency中将返回2百万,那么更新频率就是2百万分之1秒更新一次此计数器.
Regards, Lu Lin Webmaster of Inside Programming http://www.lu0s1.com
Tom.Cat
禁止发言
禁止发言
  • 注册日期2001-10-10
  • 最后登录2019-07-29
  • 粉丝1
  • 关注0
  • 积分-53792分
  • 威望197411点
  • 贡献值0点
  • 好评度5点
  • 原创分0分
  • 专家分0分
  • 社区居民
6楼#
发布于:2002-11-27 09:50
用户被禁言,该主题自动屏蔽!
ice_fire333
驱动老牛
驱动老牛
  • 注册日期2002-10-08
  • 最后登录2007-08-13
  • 粉丝0
  • 关注0
  • 积分31分
  • 威望4点
  • 贡献值0点
  • 好评度1点
  • 原创分0分
  • 专家分0分
7楼#
发布于:2002-11-26 17:31
KeQueryPerformanceCounter
LARGE_INTEGER
  KeQueryPerformanceCounter(
  IN PLARGE_INTEGER  PerformanceFrequency  OPTIONAL
  );
KeQueryPerformanceCounter provides the finest grained running count available in the system.

Parameters
PerformanceFrequency
Specifies an optional pointer to a variable that is to receive the performance counter frequency.
Include
wdm.h or ntddk.h

Return Value
KeQueryPerformanceCounter returns the performance counter value in units of ticks.

Comments
KeQueryPerformanceCounter always returns a 64-bit integer representing the number of ticks. Accumulating the count begins when the system is booted. The count is in ticks; the frequency is reported by PerformanceFrequency if this optional parameter is supplied.

The resolution of the timer used to accumulate the current count can be obtained by specifying PerformanceFrequency. For example, if the returned PerformanceFrequency is 2 million, each tick is 1/2 millionth of a second. Each 1/x millionth increment of the count corresponds to one second of elapsed time.

KeQueryPerformanceCounter is intended for time-stamping packets or for computing performance and capacity measurements. It is not intended for measuring elapsed time, for computing stalls or waits, or for iterations.

Use this routine as infrequently as possible. Depending on the platform, KeQueryPerformanceCounter can disable system-wide interrupts for a minimal interval. Consequently, calling this routine frequently or repeatedly, as in an iteration, defeats its purpose of returning very fine-grained, running time-stamp information. Calling this routine too frequently can degrade I/O performance for the calling driver and for the system as a whole.

解释的挺详细,还是搞不清是什么东西???郁闷!!!
赵客缦胡缨,吴钩霜雪明。银鞍照白马,飒沓如流星。   十步杀一人,千里不留行。事了拂衣去,深藏身与名。   闲过信陵饮,脱剑膝前横。将炙啖朱亥,持觞劝侯嬴。   三杯吐然诺,五岳倒为轻。眼花耳热后,意气素霓生。   救赵挥金槌,邯郸先震惊。千秋二壮士,煊赫大梁城。   纵死侠骨香,不惭世上英。谁能书阁下。白首太玄经。
游客

返回顶部