> On 15 Sep 2025, at 4:08 PM, Christophe Leroy <christophe.le...@csgroup.eu>
> wrote:
>
>
>
> Le 15/09/2025 à 12:29, Athira Rajeev a écrit :
>> The pseries Shared Processor Logical Partition(SPLPAR) machines can
>> retrieve a log of dispatch and preempt events from the hypervisor
>> using data from Disptach Trace Log(DTL) buffer. With this information,
>> user can retrieve when and why each dispatch & preempt has occurred.
>> The vpa-dtl PMU exposes the Virtual Processor Area(VPA) DTL counters
>> via perf.
>> - Patches 1 to 6 has powerpc PMU driver code changes to capture DTL
>> trace in perf.data. And patch 7 has documentation update.
>> Infrastructure used
>> ===================
>> The VPA DTL PMU counters do not interrupt on overflow or generate any
>> PMI interrupts. Therefore, hrtimer is used to poll the DTL data. The timer
>> nterval can be provided by user via sample_period field in nano seconds.
>> vpa dtl pmu has one hrtimer added per vpa-dtl pmu thread. DTL (Dispatch
>> Trace Log) contains information about dispatch/preempt, enqueue time etc.
>> We directly copy the DTL buffer data as part of auxiliary buffer and it
>> will be processed later. This will avoid time taken to create samples
>> in the kernel space. The PMU driver collecting Dispatch Trace Log (DTL)
>> entries makes use of AUX support in perf infrastructure. On the tools side,
>> this data is made available as PERF_RECORD_AUXTRACE records.
>> To corelate each DTL entry with other events across CPU's, an auxtrace_queue
>> is created for each CPU. Each auxtrace queue has a array/list of auxtrace
>> buffers.
>> All auxtrace queues is maintained in auxtrace heap. The queues are sorted
>> based on timestamp. When the different PERF_RECORD_XX records are processed,
>> compare the timestamp of perf record with timestamp of top element in the
>> auxtrace heap so that DTL events can be co-related with other events
>> Process the auxtrace queue if the timestamp of element from heap is
>> lower than timestamp from entry in perf record. Sometimes it could happen
>> that
>> one buffer is only partially processed. if the timestamp of occurrence of
>> another event is more than currently processed element in the queue, it will
>> move on to next perf record. So keep track of position of buffer to continue
>> processing next time. Update the timestamp of the auxtrace heap with the
>> timestamp
>> of last processed entry from the auxtrace buffer.
>> This infrastructure ensures dispatch trace log entries can be corelated
>> and presented along with other events like sched.
>> With the kernel changes;
>> # ls /sys/devices/vpa_dtl/
>> events format perf_event_mux_interval_ms power subsystem type uevent
>> Thanks
>> Athira
>
> What is the difference between this version of the series and the V2 sent 3
> hours ago ?
Hi Christophe,
Change is in Patch 7 for Documentation, where build warning for “make htmldocs”
is handled.
I added in changelog here as part of patch 7:
https://lore.kernel.org/linux-perf-users/bc6c17d2-298b-4629-9de1-dcecc3aac...@csgroup.eu/T/#m7fb311c8b56c71e7077f3f7e790805dab11b548a
There is no changes in other patches.
Sorry, I should have added that here in cover letter too along with having in
patch 7.
Thanks
Athira
>
> Christophe