Jump to content

High Precision Event Timer: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
Cascadian (talk | contribs)
No edit summary
Line 22: Line 22:
[[Windows XP]], [[Windows Server 2003]], and earlier [[Microsoft Windows|Windows]] versions, older [[Linux]] versions.
[[Windows XP]], [[Windows Server 2003]], and earlier [[Microsoft Windows|Windows]] versions, older [[Linux]] versions.


[[Microsoft]] [[Windows XP]], SP2 ''does'' support the HPET timer. When enabled on an [[Intel]] DQ45CB motherboard, a [[Microsoft]] provided [[WHQL]] driver called "High Precision Event Timer" can be seen in START / SETTINGS / CONTROL_PANEL / SYSTEM / DEVICE_MANAGER / SYSTEM_DEVICES.
[[Microsoft]] [[Windows XP]], SP2 ''does'' support the HPET timer. When enabled on an [[Intel]] DQ45CB motherboard, a [[Microsoft]] provided [[WHQL]] driver called "High Precision Event Timer" can be seen in START / SETTINGS / CONTROL_PANEL / SYSTEM / DEVICE_MANAGER / SYSTEM_DEVICES. However it is not utilized.


The following operating systems are known to be able to use HPET:
The following operating systems are known to be able to use HPET:

Revision as of 01:28, 4 September 2009

The High Precision Event Timer is a hardware timer used in computers. It was developed jointly by Intel and Microsoft. Formerly referred to by Intel as a Multimedia Timer[1], the term HPET was selected to avoid confusion with the Multimedia Timer [2] software feature introduced in Windows 95 (see Multimedia Timers).

Older operating systems do not support HPET and can only use older timing facilities, such as an RTC (see below.)

Features

An HPET block consists of a fixed-rate up-counter and 3 to 32 independent timers, each of which consists of a comparator and a register for storing a trigger value. There can be at most 8 HPET blocks. Each comparator can generate an interrupt when the counter reaches a pre-programmed value.

All timers can be put into one-shot mode and some may also support a periodic mode. In one-shot mode the timer fires an interrupt once when the main counter reaches the value stored in the comparator's register. In the periodic mode the interrupts are generated at specified intervals.

Applications

The HPET can produce periodic interrupts at a much higher resolution than the RTC and is often used to synchronize multimedia streams, providing smooth playback and reducing the need to use other timestamp calculations such as an x86 CPU's RDTSC instruction.

Comparison to predecessors

HPET is meant to supplement and replace the 8254 Programmable Interval Timer (PIT) and the Real-time clock's (RTC) periodic interrupt function. Compared to these older timer circuits, the HPET has higher frequency (at least 10 MHz) and wider 64-bit counters (although they can be driven in 32-bit mode).[1]

While 8254 and RTC can, similarly to HPET, be put in one-shot mode, the set-up process is so slow that their one-shot mode is not used in practice for tasks requiring precise scheduling.[3] Instead, 8254 and RTC are typically used in periodic mode with very small time interval. For example, if an application needs to perform several short (some milliseconds, perhaps) waits, it is better to have a periodic timer running constantly with 1 ms period because of the high setup cost of an 8254 or RTC one-shot timer. This causes an interrupt on every millisecond even if the application needs to do actual work less frequently. With HPET, the extra interrupts can be avoided, because the set-up cost of a HPET one-shot timer is considerably smaller.

Compatibility

Operating systems designed before HPET existed cannot use HPET, so work only on hardware that has other timer facilities. Newer operating systems tend to be able to use either. Some hardware has both.

The following operating systems are known not to be able to use HPET: Windows XP, Windows Server 2003, and earlier Windows versions, older Linux versions.

Microsoft Windows XP, SP2 does support the HPET timer. When enabled on an Intel DQ45CB motherboard, a Microsoft provided WHQL driver called "High Precision Event Timer" can be seen in START / SETTINGS / CONTROL_PANEL / SYSTEM / DEVICE_MANAGER / SYSTEM_DEVICES. However it is not utilized.

The following operating systems are known to be able to use HPET: Windows Vista, Windows 2008, Windows 7, x86 based versions of Mac OS X, Linux operating systems using the 2.6 kernel and FreeBSD.

With a Linux kernel, you need the newer "rtc-cmos" hardware clock device driver rather than the original "rtc" driver.

See also

References

  1. ^ a b Intel Corporation, IA-PC HPET (High Precision Event Timers) Specification (revision 1.0a) (PDF), retrieved 2007-07-16 {{citation}}: Unknown parameter |month= ignored (help)
  2. ^ Multimedia Timers
  3. ^ Guidelines For Providing Multimedia Timer Support ([dead link]Scholar search), 2002-09-20, retrieved 2007-07-16 {{citation}}: External link in |format= (help)