[Intel-gfx] [RFC PATCH 1/3] drm/i915/perf: allow holding preemption on filtered ctx

Lionel Landwerlin lionel.g.landwerlin at intel.com
Mon Oct 8 15:45:44 UTC 2018


On 08/10/2018 16:35, Chris Wilson wrote:
> Quoting Lionel Landwerlin (2018-10-08 16:18:20)
>> We would like to make use of perf in Vulkan. The Vulkan API is much
>> lower level than OpenGL, with applications directly exposed to the
>> concept of command buffers (pretty much equivalent to our batch
>> buffers). In Vulkan, queries are always limited in scope to a command
>> buffer. In OpenGL, the lack of command buffer concept meant that
>> queries' duration could span multiple command buffers.
>>
>> With that restriction gone in Vulkan, we would like to simplify
>> measuring performance just by measuring the deltas between the counter
>> snapshots written by 2 MI_RECORD_PERF_COUNT commands, rather than the
>> more complex scheme we currently have in the GL driver, using 2
>> MI_RECORD_PERF_COUNT commands and doing some post processing on the
>> stream of OA reports, coming from the global OA buffer, to remove any
>> unrelated deltas in between the 2 MI_RECORD_PERF_COUNT.
>>
>> Disabling preemption only apply to a single context with which want to
>> query performance counters for and is considered a privileged
>> operation, by default protected by CAP_SYS_ADMIN. It is possible to
>> enable it for a normal user by disabling the paranoid stream setting.
> I'm am uncomfortable with disabling preemption like this. I suggest we
> at least have the preemption timeout in place first.
> -Chris
>
Sure, I'm not super happy about that either but that's the hardware we 
have to work with :/



More information about the Intel-gfx mailing list