summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_nir_tcs_workarounds.c
Commit message (Collapse)AuthorAgeFilesLines
* i965: Safely iterate the predecessors of the end block.Kenneth Graunke2016-08-251-9/+14
| | | | | | | | | | | | | | We want to insert code in each of the predecessors of the end block. This code includes a nir_if, which would split the block, altering the set. To avoid that, I emitted a dead constant at the end of each block before splitting it, so that the set of predecessors remained unchanged. This was admittedly ugly. Connor suggested instead saving a copy of the set, so we can iterate it safely. This is also a little ugly, but a much better plan. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
* nir: Use nir_shader_get_entrypoint in TCS quad workaround code.Kenneth Graunke2016-08-251-12/+9
| | | | | | | | | | | | | | We want to insert the code at the end of the program. Looping over all the functions (of which there was only one) was the old way of doing this, but now we have nir_shader_get_entrypoint(), so let's use it. Suggested by Connor Abbott. v2: Update for nir_shader_get_entrypoint API change. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
* i965: Implement the WaPreventHSTessLevelsInterference workaround.Kenneth Graunke2016-08-181-0/+152
Fixes several GL44-CTS.tessellation_shader (and GL45 and ES31) subcases: - vertex_spacing - tessellation_shader_point_mode.points_verification - tessellation_shader_quads_tessellation.inner_tessellation_level_rounding Cc: mesa-stable@lists.freedesktop.org Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Alejandro PiƱeiro <apinheiro@igalia.com>