---
name: "latency"
section: "1"
platform: "linux"
package: "xenomai-runtime"
version: "2.6.3-2"
release: "Debian 8 (Jessie)"
platforms: ["linux", "macos"]
url: "https://new.carta.tech/latency"
---

# latency(1)

Xenomai timer latency benchmark

## NAME

latency - Xenomai timer latency benchmark

## SYNOPSIS

**latency** \[ options \]

## DESCRIPTION

**latency** is part of the Xenomai test suite. It is a timer latency benchmark program. The system must run a suitable Xenomai enabled kernel with the respective module (xeno\_timerbench).

## OPTIONS

**latency** accepts the following options:

- **-h**

  print histograms of min, avg, max latencies

- **-g \<file\>**

  dump histogram to \<file\> in a format easily readable with gnuplot. An example script for gnuplot may be found in scripts/histo.gp in Xenomai sources distribution

- **-s**

  print statistics of min, avg, max latencies

- **-H \<histogram-size\>**

  default = 200, increase if your last bucket is full

- **-B \<bucket-size\>**

  default = 1000ns, decrease for more resolution

- **-p \<period\_us\>**

  sampling period

**-l \<data-lines per header\>**

default=21, 0 to supress headers

- **-T \<test\_duration\_seconds\>**

  default=0, so ^C to end

- **-q**

  supresses RTD, RTH lines if -T is used

- **-D \<testing\_device\_no\>**

  number of testing device, default=0

- **-t \<test\_mode\>**

  0=user task (default), 1=kernel task, 2=timer IRQ

- **-f**

  freeze trace for each new max latency

- **-c \<cpu\>**

  pin measuring task down to given CPU

- **-P \<priority\>**

  task priority (test mode 0 and 1 only)

- **-b**

  break upon mode switch

## AUTHOR

**latency** was written by Philippe Gerum. This man page was written by Roland Stigge.
