From db923fa823354270217362db06356f2b1a41315e Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Tue, 10 Nov 2026 11:39:20 -0300 Subject: ztrace perf: the kernel's view of a program, unprivileged perf_event_open on a held child: counters, a sampling profile, every page fault with its registers, maps, threads, context switches, every syscall (the per-syscall tracepoints, the only ones open to a user), and the debug registers as watchpoints and breakpoints that do not stop the target. One time-ordered stream of Events into a Sink; --threads follows with a ring per CPU. usdt.zig: the notes of and their arguments from a Regs and a memory reader, independent of BPF. test-kernel runs all of it on targets/kernel_*. Co-Authored-By: Claude Fable 5.2 --- src/trace/root.zig | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/trace/root.zig') diff --git a/src/trace/root.zig b/src/trace/root.zig index fd91d9a..80745cb 100644 --- a/src/trace/root.zig +++ b/src/trace/root.zig @@ -16,6 +16,10 @@ pub const syscalls = @import("syscalls.zig"); pub const client = @import("client.zig"); /// Inside the tracer: a target running with a ring. pub const host = @import("host.zig"); +/// The kernel's view, unprivileged: counters, samples, faults, maps, syscalls, watchpoints. +pub const perf = @import("perf.zig"); +/// Static probes (the ELF notes of ) and their arguments. +pub const usdt = @import("usdt.zig"); test { _ = event; @@ -27,4 +31,6 @@ test { _ = syscalls; _ = client; _ = host; + _ = perf; + _ = usdt; } -- cgit v1.3