How context switches affect MALI GPU PMU?

Hello,

I would like to understand how the Performance Monitoring Unit (PMU) behaves during context switches on the GPU.

For example, if task A is running and PMU_Counter1 reaches a value of 56, then the scheduler removes task A and switches to task B. When task B begins execution, what happens to the value of PMU_Counter1? Does it reset to 0, isolating task B from task A, or does it retain the previous value of 56 from task A, since both tasks are using the same partition?

In other words, how do context switches impact the Performance Monitor Counters on the MALI G78AE GPU? Are the counters specific to each task, or do they reflect the partition's activity regardless of which task is running?

Thank you,
Luca

Parents
  • Hi Luca, 

    GPU counters represent the global workload for a single partition, so include all running contexts.

    The counter sampling is virtualized in the kernel driver, so you can have multiple sampling processes and they will see correct values relative to their own samples. One process sampling won't zero the counters for other processes.

    Kind regards, 
    Pete

Reply
  • Hi Luca, 

    GPU counters represent the global workload for a single partition, so include all running contexts.

    The counter sampling is virtualized in the kernel driver, so you can have multiple sampling processes and they will see correct values relative to their own samples. One process sampling won't zero the counters for other processes.

    Kind regards, 
    Pete

Children