pt_buffer_setup_aux(9)
π pt_buffer_setup_aux(9) π
okay so bestie, welcome to the Kernel API Manual β we're literally about to set up ToPA tables together and it's gonna slay β¨
πΈ NAME πΈ
pt_buffer_setup_aux β set up topa tables for a PT buffer π
π¦ SYNOPSIS π¦
void * pt_buffer_setup_aux (struct perf_event *event , void **pages ,
int nr_pages , bool snapshot );
β¨ ARGUMENTS β¨
eventβ the performance event, your main character π«Άpagesβ array of pointers to buffer pages, handed down from perf corenr_pagesβ how many pages are in the buffer, no capsnapshotβ if this is a snapshot/overwrite counter π
π DESCRIPTION π
so this is a pmu::setup_aux callback, and what it does is set up the ToPA tables and all the bookkeeping for an AUX buffer. like, the whole entire vibe. tables? handled. bookkeeping? handled. iconic behaviour only π
π₯ RETURN π₯
our private PT buffer structure π (it's ours, we made it, we're obsessed)
π SEE ALSO π
honestly the whole friend group showed up for this one:
struct topa(9)struct topa_page(9)topa_alloc(9)topa_free(9)topa_insert_table(9)topa_table_full(9)topa_insert_pages(9)pt_topa_dump(9)pt_buffer_advance(9)pt_update_head(9)pt_buffer_region(9)pt_buffer_region_size(9)pt_handle_status(9)pt_read_offset(9)pt_buffer_reset_markers(9)pt_buffer_reset_offsets(9)pt_buffer_fini_topa(9)pt_buffer_init_topa(9)pt_buffer_free_aux(9)intel_pt_interrupt(9)
bestie this one lives in the kernel file ./arch/x86/events/intel/pt.c β go read it iykyk π
and that's the whole page!! mwah π this came out of ./arch/x86/events/intel, dated October 2026, and it's genuinely giving reference documentation. periodt. ππ§π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms