Article ID: 895980 - Last Review: July 17, 2008 - Revision: 5.1

Programs that use the QueryPerformanceCounter function may perform poorly in Windows Server 2000, in Windows Server 2003, and in Windows XP

On This Page

Expand all | Collapse all

SYMPTOMS

In Windows Server 2000, Windows Server 2003, and Windows XP, a program that uses the QueryPerformanceCounter function to query system time may perform poorly. For example, if you run the ping command at the command prompt, you may receive low or incorrect latency values.

Note This problem occurs on computers that are running an x64-based version of Windows or an x86-based (32-bit) version of Windows.

CAUSE

This problem occurs when the computer has the AMD Cool'n'Quiet technology enabled in the BIOS.

RESOLUTION

To resolve this problem, install the new AMD CPU driver. To do this, visit the following AMD Web site:
http://www.amd.com/us-en/assets/content_type/utilities/setup.zip (http://www.amd.com/us-en/assets/content_type/utilities/setup.zip)
After you install the new driver, you must restart your computer.

Note The driver installation adds the /usepmtimer switch in the Boot.ini file. This switch is discussed in the "Workaround" section.

WORKAROUND

To work around this problem, update the BIOS on the computer. Or, modify the Boot.ini file to use the /usepmtimer switch. To do this, follow these steps:
  1. Log on to the computer by using an account that has administrative credentials.
  2. Click Start, click Run, type notepad c:\boot.ini, and then click OK.
  3. In the Boot.ini file, a line that starts with "default" is located in the "[boot loader]" section. This line specifies the location of the default operating system. The line may appear as follows:
    default=multi(0)disk(0)rdisk(0)partition(2)\WINDOWS
    In the "[operating systems]" section, locate the line for the operating system that corresponds to the "default" line. For example, if the computer is running Microsoft Windows Server 2003, Enterprise x64 Edition, the line should resemble the following:
    multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Windows Server 2003 Enterprise x64 Edition" /fastdetect /NoExecute=OptIn
  4. At the end of the line, add a space, and then type /usepmtimer. The line should now resemble the following.
    multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Windows Server 2003 Enterprise x64 Edition" /fastdetect /NoExecute=OptIn /usepmtimer
  5. Save the file, and then exit Notepad.
  6. Restart the computer.
The following is a sample Boot.ini file for a system that contains the /usepmtimer switch.
[boot loader]
timeout=0
default=multi(0)disk(0)rdisk(0)partition(2)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(2)\WINDOWS="Windows Server 2003 Enterprise x64 Edition" /fastdetect /NoExecute=OptIn /usepmtimer
Note The Boot.ini file is located in the root folder of the system drive.

MORE INFORMATION

By default, Windows Server 2003 Service Pack 2 (SP2) uses the PM timer for all multiprocessor APIC or ACPI HALs, unless the check process to determine whether the BIOS supports the APIC or ACPI HALs fails. If you are not running Windows Server 2003 SP2, you must force the AMD computer to use the PM timer by using the /usepmtimer switch.

Note The decision to use the PM timer or the TSC timer is made during a check that is performed at startup to query the BIOS and to determine whether the BIOS will support the PM timer functions. This check is not completely accurate on AMD chipsets. Therefore, you must use the /usepmtimer switch.

In Windows Server 2003 SP2, this section of code was rewritten. Therefore, the correct performance monitor data appears on AMD chipsets that have Windows Server 2003 SP2 installed, and you do not have to use the /usepmtimer switch.

For more information about ACPI and APCI hardware support, click the following article number to view the article in the Microsoft Knowledge Base:
309283  (http://support.microsoft.com/kb/309283/ ) HAL options after Windows XP or Windows Server 2003 Setup

Technical support for x64-based versions of Microsoft Windows

If your hardware came with a Microsoft Windows x64 edition already installed, your hardware manufacturer provides technical support and assistance for the Windows x64 edition. In this case, your hardware manufacturer provides support because a Windows x64 edition was included with your hardware. Your hardware manufacturer might have customized the Windows x64 edition installation by using unique components. Unique components might include specific device drivers or might include optional settings to maximize the performance of the hardware. Microsoft will provide reasonable-effort assistance if you need technical help with a Windows x64 edition. However, you might have to contact your manufacturer directly. Your manufacturer is best qualified to support the software that your manufacturer installed on the hardware. If you purchased a Windows x64 edition such as a Microsoft Windows Server 2003 x64 edition separately, contact Microsoft for technical support.

For product information about Microsoft Windows XP Professional x64 Edition, visit the following Microsoft Web site:
http://www.microsoft.com/windowsxp/64bit/default.mspx (http://www.microsoft.com/windowsxp/64bit/default.mspx)
For product information about x64-based versions of Microsoft Windows Server 2003, visit the following Microsoft Web site:
http://www.microsoft.com/windowsserver2003/64bit/x64/editions.mspx (http://www.microsoft.com/windowsserver2003/64bit/x64/editions.mspx)
The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, regarding the performance or reliability of these products.

APPLIES TO
  • Microsoft Windows Server 2003, Datacenter x64 Edition
  • Microsoft Windows Server 2003, Enterprise x64 Edition
  • Microsoft Windows Server 2003, Standard x64 Edition
  • Microsoft Windows Server 2003, Datacenter Edition (32-bit x86)
  • Microsoft Windows Server 2003, Enterprise Edition (32-bit x86)
  • Microsoft Windows Server 2003, Standard Edition (32-bit x86)
  • Microsoft Windows Server 2003, Web Edition
  • Microsoft Windows XP Professional x64 Edition
  • Microsoft Windows XP Professional
  • Microsoft Windows 2000 Enterprise Edition
  • Microsoft Windows 2000 Standard Edition
  • MS Windows 2000 Server
Keywords: 
kbtshoot kbprb KB895980
 

Article Translations