Compartilhar via


ILTiming.exe

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

ILTiming.exe determines the interrupt service routine (ISR) and interrupt service thread (IST) latencies. By default, this tool uses the system tick interrupt as the test interrupt vector. However, not all hardware platforms have an unused timer available.

To determine the ISR and IST interrupt latencies, ILTiming.exe sets the timer to return SYSTINTR_TIMING at specified tick intervals. ILTiming.exe waits for the SYSINTR_TIMING interrupt event, thus becoming the IST. ILTiming.exe gets the current time each time it receives the SYSTINTR_TIMING message.

Message Description

ILTIMING_MSG_ENABLE

The OAL uses the system tick to cause a SYSINTR_TIMING interrupt event. No structure fields are updated.

ILTIMING_MSG_DISABLE

The OAL unhooks the system tick from the timer, causing a SYSINTR_TIMING interrupt event. No structure fields are updated.

ILTIMING_MSG_GET_TIMES

The OAL fills in all structure fields except pfnPerfCountSinceTick.

ILTIMING_MSG_GET_PFN

This function is called in kernel mode directly from the application to minimize overhead.

**ILTiming requires special modifications to the OAL, but not the kernel. It should run on any of the samples and design templates.

You can use the following command-line parameters with the ILTiming.exe tool.

iltiming [-i0] [-i1] [-i2] [-i3] [-i4] [-p priority] [-ni]
[-t interval] [-n interrupt] [-all] [-o file_name] [-h]

The following table shows the command-line parameters used with ILTiming.

Command-line parameter Description

-i0

Indicates that there is no idle thread. This is equivalent to using the -ni parameter.

-i1

Runs idle thread type 1.

-i2

Runs idle thread type 2.

-i3

Runs idle thread type 3.

-i4

Runs idle thread type 4.

-i5

Runs idle thread type 5.

-p priority

Indicates the IST priority. The default setting is zero, for highest priority.

-ni

Indicates that there is no idle priority thread. The default setting is equal to the number of idle priority thread spins. This is equivalent to using the -i0 parameter.

-t interval

Indicates the SYSINTR_TIMING timing interval, with clock ticks in milliseconds. The default setting is 5.

-n interrupt

Indicates the number of interrupts. The default setting is 10.

-all

Specifies to output all data. The default setting is to output the summary only.

-o file_name

Specifies to output to file. The default setting is to output to the debugger message window.

-h

Displays a Help screen.

You can choose to run the IST at one of the 256 priority levels by using the -p parameter.

You may have an idle thread running in the background that affects the IST latencies by enabling the kernel to be in a non-preemptive kernel call that must finish before the IST is run. The idle thread types are described in the following table.

Idle Thread Type Description

Idle thread 1

One thread spinning.

Idle thread 2

One thread spinning, calling SetThreadPriority (THREAD_PRIORITY_IDLE).

Idle thread 3

Two threads alternating SetEvent and WaitForSingleObject with a 10-second time out.

Idle thread 4

Two threads alternating SetEvent and WaitForSingleObject with an infinite timeout.

Idle thread 5

One thread spinning, calling either VirtualAlloc or VirtualFree, or both. Designed to flush the cache and the translation look-aside buffer (TLB).

The ISR rate is set by the -t parameter. The following command line entry causes the system tick ISR to return SYSINTR_TIMING every tenth tick:

iltiming -t10

The source code for ILTiming.exe is included in Platform Builder.

See Also

Concepts

Real-Time Measurement Tools

Other Resources