mesa/src/intel
Francisco Jerez 03f6edd5b7 intel/fs: Add physical fall-through CFG edge for unconditional BREAK instruction.
This adds a missing CFG edge that represents a possible physical
control flow path the EU might take under some conditions which isn't
part of the logical CFG of the program.  This possibility shouldn't
have led to problems on platforms prior to Gfx12, since the missing
control flow edge cannot possibly influence liveness intervals.
However on Gfx12+ it becomes the compiler's responsibility to resolve
data dependencies across instructions, and the missing physical
control flow paths may lead to a WaR data hazard currently not visible
to the software scoreboard pass, which could lead to data corruption.

Worse, the possibility for this path to be taken by the EU increases
on Gfx12+ due to a hardware bug affecting EU fusion -- However the
same physical path can be potentially taken on earlier platforms as
well, so this patch extends the CFG on all platforms for consistency,
even though the lack of this edge shouldn't lead to any functional
issues on platforms earlier than Gfx12.  There are no shader-db
changes on earlier platforms, so there seems to be no disadvantage
from using the same CFG representation as on later platforms.

This issue has ben reported on TGL with the following conformance
test, thanks to Ian for bringing the FULSIM dependency check warning
to my attention:

   dEQP-VK.graphicsfuzz.spv-stable-pillars-volatile-nontemporal-store

Fixes: 4d1959e693 ("intel/cfg: Represent divergent control flow paths caused by non-uniform loop execution.")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/4940
Reported-by: Tapani Pälli <tapani.palli@intel.com>
Reported-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14248>
(cherry picked from commit e7470a40c5)
2021-12-29 20:56:29 +00:00
..
blorp intel/blorp: fix a compile warning about uninitialized use 2021-10-05 11:59:27 +00:00
common intel: Add and use max_constant_urb_size_kb 2021-09-27 20:51:28 +00:00
compiler intel/fs: Add physical fall-through CFG edge for unconditional BREAK instruction. 2021-12-29 20:56:29 +00:00
dev intel/devinfo: fix wrong offset computation 2021-11-10 21:58:04 +00:00
ds pps: Avoid duplicate elements in with_datasources array. 2021-09-29 07:26:18 +00:00
genxml intel/genxml: Fix MI_FLUSH_DW to actually specify the length properly 2021-11-17 20:06:22 +00:00
isl intel: fix INTEL_DEBUG environment variable on 32-bit systems 2021-10-20 20:40:58 +01:00
nullhw-layer intel/nullhw: fix build 2021-03-26 20:12:40 +00:00
perf intel/perf: fix perf equation subslice mask generation for gfx12+ 2021-11-10 21:58:04 +00:00
tools intel/stub: Silence "initialized field overwritten" warning 2021-12-17 22:30:50 +00:00
vulkan anv: Stop doing too much per-sample shading 2021-12-17 22:30:50 +00:00
Makefile.perf.am intel: Rename GEN_PERF prefix to INTEL_PERF in build files 2021-04-20 20:06:34 +00:00
meson.build pps: Intel pps driver 2021-05-18 14:28:48 +00:00