Skip to content

i965, anv, iris: Implement NV_compute_shader_derivatives

Overview:

In unextended OpenGL, the GLSL shading language supports derivatives in fragment shaders, which are computed on shader inputs or on other computed values using fragments' (x,y) coordinates as the domain. Derivatives are not supported in any other shader stage. However, compute shaders also arrange shader invocations in a three-dimensional array with (x,y,z) coordinates. This extension provides a mechanism where compute shaders can similarly evaluate derivatives using the x and y coordinates of the local invocation ID across a set of invocations with identical z coordinates.

The more important changes are in the two commits in intel/fs. The rest is either extension boilerplate or passing information around.

Tests:

References:

Edited by Caio Oliveira

Merge request reports