<feed xmlns='http://www.w3.org/2005/Atom'>
<title>computeranim.git/build/kernel.zig, branch main</title>
<subtitle>Tracing debugger and animations of running programs (ztrace, canim)</subtitle>
<id>https://git.0x4200.cafe/computeranim.git/atom?h=main</id>
<link rel='self' href='https://git.0x4200.cafe/computeranim.git/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://git.0x4200.cafe/computeranim.git/'/>
<updated>2026-11-10T15:30:52Z</updated>
<entry>
<title>static probes from the debugger: -b usdt:PROVIDER:NAME, no root</title>
<updated>2026-11-10T15:30:52Z</updated>
<author>
<name>Gabriel Schneider</name>
<email>gbrls@0x4200.cafe</email>
</author>
<published>2026-11-10T15:28:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0x4200.cafe/computeranim.git/commit/?id=8ac0639bfc0186acedb11759432a2cfa277193f2'/>
<id>urn:sha1:8ac0639bfc0186acedb11759432a2cfa277193f2</id>
<content type='text'>
Debugger.usdt arms the USDT probes of every mapped module as breakpoints
whose hook records a probe event with its arguments and lets the program
run on, raising a probe's semaphore first; record and dbg take
usdt:PROVIDER:NAME (* for any), running the loader through when the probe
is a library's. glibc's own 78 probes are there for the asking:
memory_sbrk_more shows malloc growing the heap.
</content>
</entry>
<entry>
<title>kernel: on today's main</title>
<updated>2026-11-10T15:23:41Z</updated>
<author>
<name>Gabriel Schneider</name>
<email>gbrls@0x4200.cafe</email>
</author>
<published>2026-11-10T15:23:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0x4200.cafe/computeranim.git/commit/?id=8008a2655c0f0c9b9890fb4866f774c9b50e170c'/>
<id>urn:sha1:8008a2655c0f0c9b9890fb4866f774c9b50e170c</id>
<content type='text'>
Symbols come from Symbols (perf.lookup is gone), string ids from
event.stringId, and ptrace.Process is used as it is now. A USDT
semaphore of the program itself is raised by the tracer: the kernel's
counter landed on the wrong word of a small lld-linked target, whose
page of the file is mapped writable twice. test-kernel also runs the
library tests of perf, usdt and bpf.

Co-Authored-By: Claude Fable 5.2 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>ztrace probe: BPF on syscalls, scheduling, kprobes, uprobes and USDT</title>
<updated>2026-11-10T15:19:06Z</updated>
<author>
<name>Gabriel Schneider</name>
<email>gbrls@0x4200.cafe</email>
</author>
<published>2026-11-10T14:49:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0x4200.cafe/computeranim.git/commit/?id=297943b01e18bb3d1dd41a8d3e220811de25228b'/>
<id>urn:sha1:297943b01e18bb3d1dd41a8d3e220811de25228b</id>
<content type='text'>
Programs built as instruction arrays for one process (no compiler, no
libbpf), writing Events into a BPF ring buffer; a drop counter in a map;
task_struct offsets from the kernel's BTF; a USDT probe's arguments read
in the kernel at the probe. Without CAP_BPF and CAP_PERFMON it says so;
--dry-run builds and lists everything. Tested offline by running the
programs in a small BPF machine, and for real by test-kernel-vm, which
boots this kernel in QEMU where we are root.

ztrace perf: moments are no longer cut per event unless --cut;
--max-size, and a full recording stops the target and says so.
perf.Sorted merges two backends' events by time.

Co-Authored-By: Claude Fable 5.2 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>ztrace perf: the kernel's view of a program, unprivileged</title>
<updated>2026-11-10T15:19:06Z</updated>
<author>
<name>Gabriel Schneider</name>
<email>gbrls@0x4200.cafe</email>
</author>
<published>2026-11-10T14:39:20Z</published>
<link rel='alternate' type='text/html' href='https://git.0x4200.cafe/computeranim.git/commit/?id=db923fa823354270217362db06356f2b1a41315e'/>
<id>urn:sha1:db923fa823354270217362db06356f2b1a41315e</id>
<content type='text'>
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 &lt;sys/sdt.h&gt; 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 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>ztrace: the event, the ring, the recording, a ptrace loop</title>
<updated>2026-11-10T14:08:49Z</updated>
<author>
<name>Gabriel Schneider</name>
<email>gbrls@0x4200.cafe</email>
</author>
<published>2026-11-10T14:08:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0x4200.cafe/computeranim.git/commit/?id=0b29354e1ddf6cf75ac4c426a00dd3435ace5069'/>
<id>urn:sha1:0b29354e1ddf6cf75ac4c426a00dd3435ace5069</id>
<content type='text'>
One 64-byte Event for every backend; a shared-memory ring from target to
tracer with stop/resume; a Recorder that folds events into xitdb moments
(registers, memory in 64-byte chunks with known-byte masks, strings) and a
Trace that reads any moment back; a minimal ptrace Process; ztrace record,
run and dump. Per-area build files so the areas grow apart.
</content>
</entry>
</feed>
