summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-02-23 13:20:52 +0200
committerPaul Buetow <paul@buetow.org>2026-02-23 13:20:52 +0200
commit2b1c849422973cf926e2bfda31703f4bfef5563d (patch)
tree6220608d1baaeaf6c09fa3fc8062a9831fbc8055 /README.md
parent95441bb43ef1ea6d003cd3b4143bbaee70f797d6 (diff)
docs: define durationToPrev timing semantics
Diffstat (limited to 'README.md')
-rw-r--r--README.md14
1 files changed, 13 insertions, 1 deletions
diff --git a/README.md b/README.md
index fb829a4..c9a57ef 100644
--- a/README.md
+++ b/README.md
@@ -10,6 +10,19 @@ Maybe this is a spiritual successor of one of my previous projects, I/O Riot htt
This works only on Linux!
+## Timing Semantics
+
+Each reported event pair has two timing counters:
+
+- `durationNs`: syscall runtime on the same thread (`exit(current) - enter(current)`).
+- `durationToPrevNs`: inter-syscall gap on the same thread (`enter(current) - exit(previous)`).
+
+Important details:
+
+- `durationToPrevNs` is tracked per `tid` (thread), not globally across all threads.
+- The first observed syscall pair for a thread has `durationToPrevNs = 0` because there is no prior exit timestamp.
+- `durationToPrevNs` is attributed to the current syscall pair (the one whose `enter` closes the gap).
+
## Fedora
To get this running on Fedora 42, run:
@@ -50,4 +63,3 @@ We are using Inferno Flamegraphs: https://github.com/jonhoo/inferno
```sh
cargo install inferno
```
-