Counting Clocks - Intel ARCHITECTURE IA-32 Reference Manual

Architecture optimization
Table of Contents

Advertisement

IA-32 Intel® Architecture Optimization
miss more than once during its life time, but a Misses Retired metric
(for example, 1
for that

Counting Clocks

The count of cycles, also known as clock ticks, forms a fundamental
basis for measuring how long a program takes to execute, and as part of
efficiency ratios like cycles per instruction (CPI). Some processor
clocks may stop "ticking" under certain circumstances:
The processor is halted, e.g. during I/O, there may be nothing for the
CPU to do while servicing a disk read request, and the processor
may halt to save power. When Hyper-Threading Technology is
enabled, both logical processors must be halted for
performance-monitoring-related counters to be powered down.
The processor is asleep, either as a result of being halted for a while,
or as part of a power-management scheme. Note that there are
different levels of sleep, and in the deeper sleep levels, the
timestamp counter stops counting.
This section describes three mechanisms to count processor clock cycles
for monitoring performance. They are:
Non-Halted Clockticks: clocks when the specified logical
processor is not halted nor in any power-saving states. These can be
measured on a per-logical-processor basis, when Hyper-Threading
Technology is enabled.
Non-Sleep Clockticks: clocks when the physical processor is not in
any of the sleep modes, nor power-saving states. These cannot be
measured on a per-logical- processor basis.
Timestamp Counter: clocks when the physical processor is not in
deep sleep. These cannot be measured on a per-logical-processor
basis.
B-4
st
-Level Cache Misses Retired) will increment only once
μ
op.

Advertisement

Table of Contents
loading

Table of Contents