Hard Processor System Technical Reference Manual: Agilex™ 5 SoCs

ID 814346
Date 11/27/2024
Public
Document Table of Contents

15.5.4. Timestamp

The following diagram shows the trace timestamp and generic counter connectivity highlighted in green, and the timestamp related IP blocks (TSGEN, TSINTP, TSREP, TSENC, NTSASYNC, TSDEC, BIN2GRY, ASYNC, GRY2BIN) highlighted in green.

Figure 325. Block Diagram for Timestamp Network

Two CoreSight Timestamp Generators are used to provide two independent 64-bit counters. One counter is for trace message timestamps, and the other counter is for the CPU’s generic counter.

The 64-bit generic counter value connects to the DSU’s CNTVALUEB[63:0] inputs. However, between the Generic Counter’s Timestamp Generator and the CNTVALUEB port, the timestamp value passes through a binary to gray code converter (bin2gry) followed by an asynchronous bridge followed by a gray code to binary converter (gry2bin).

For trace timestamps, the 10-bit CoreSight narrow timestamp (NTS) is used to reduce routing requirements. The 64-bit trace timestamp generated is then replicated (tsrep) 4 times and the encoded (tsenc) to the 10-bit NTS before being synchronized (ntsasync) and then decoded (tsdec) back to a 64-bit timestamp and connected to the trace module (STM, PSS NOC Probes, MPFE NOC Probes, and the DSU’s TSVALUEB).

The DSU implements a timestamp interpolator (tsintp) to provide fine granularity timestamps to the ETMs running at higher Arm* core clock frequencies. The interpolator shifts the input timestamp left by 8 bits, and uses the extra low-order bits to provide a more accurate timestamp value. The greater accuracy is achieved by monitoring changes to the input timestamp value over time to predict how fast it counts.