---
name: "rte_timecounter"
section: "3"
platform: "linux"
package: "dpdk-doc"
version: "24.11.4-0+deb13u1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/rte_timecounter"
---

# rte\_timecounter(3)

## NAME

rte\_timecounter

## SYNOPSIS

`#include <rte_time.h>`

### Data Fields

uint64\_t **cycle\_last**\
 uint64\_t **nsec**\
 uint64\_t **nsec\_mask**\
 uint64\_t **nsec\_frac**\
 uint64\_t **cc\_mask**\
 uint32\_t **cc\_shift**\

## Detailed Description

Structure to hold the parameters of a running cycle counter to assist in converting cycles to nanoseconds.

Definition at line **21** of file **rte\_time.h**.

## Field Documentation

### uint64\_t cycle\_last

Last cycle counter value read.

Definition at line **23** of file **rte\_time.h**.

### uint64\_t nsec

Nanoseconds count.

Definition at line **25** of file **rte\_time.h**.

### uint64\_t nsec\_mask

Bitmask separating nanosecond and sub-nanoseconds.

Definition at line **27** of file **rte\_time.h**.

### uint64\_t nsec\_frac

Sub-nanoseconds count.

Definition at line **29** of file **rte\_time.h**.

### uint64\_t cc\_mask

Bitmask for two's complement subtraction of non-64 bit counters.

Definition at line **31** of file **rte\_time.h**.

### uint32\_t cc\_shift

Cycle to nanosecond divisor (power of two).

Definition at line **33** of file **rte\_time.h**.

## Author

Generated automatically by Doxygen for DPDK from the source code.
