mesa/src
Eduardo Lima Mitev 2e4525883f ir3/compiler: Enable lower_io_offsets pass and handle new SSBO intrinsics
These intrinsics have the offset in dwords already computed in the last
source, so the change here is basically using that instead of emitting
the ir3_SHR to divide the byte-offset by 4.

The improvement in shader stats is significant, of up to ~15% in
instruction count in some cases. Tested only on a5xx.

shader-db is unfortunately not very useful here because shaders that use
SSBO require GLSL versions that are not supported by freedreno yet.

For examples, most Khronos CTS tests under 'dEQP-GLES31.functional.ssbo.*'
are helped.

A random case:

dEQP-GLES31.functional.ssbo.layout.2_level_array.packed.row_major_mat3x2

with current master:

; CL prog 14/1: 1252 instructions, 0 half, 48 full
; 8 const, 8 constlen
; 61 (ss), 43 (sy)

with the SSBO dword-offset moved to NIR:

; CL prog 14/1: 1053 instructions, 0 half, 45 full
; 7 const, 7 constlen
; 34 (ss), 73 (sy)

The SHR previously emitted for every single SSBO instruction disappears
in most cases, and the dword-offset ends up embedded in the STGB
instruction as immediate in many cases as well.

There are also a few of those tests that are currently failing on register
allocation, that start to pass as a result of reducing the pressure. At least
these, probably more:

dEQP-GLES31.functional.ssbo.layout.random.unsized_arrays.24
dEQP-GLES31.functional.ssbo.layout.random.arrays_of_arrays.6
dEQP-GLES31.functional.ssbo.layout.random.arrays_of_arrays.17
dEQP-GLES31.functional.ssbo.layout.random.nested_structs_arrays.14
dEQP-GLES31.functional.ssbo.layout.random.nested_structs_arrays_instance_arrays.5
dEQP-GLES31.functional.ssbo.layout.random.nested_structs_arrays_instance_arrays.7

No regressions observed with relevant CTS and piglit tests.

Reviewed-by: Rob Clark <robdclark@gmail.com>
2019-03-13 21:19:44 +01:00
..
amd ac: use the raw tbuffer version for 16-bit SSBO loads 2019-03-13 14:16:14 +01:00
broadcom v3d: Fix leak of the mem_ctx after the DAG refactor. 2019-03-12 16:15:40 -07:00
compiler nir: Add ir3-specific version of most SSBO intrinsics 2019-03-13 21:19:44 +01:00
egl egl/dri: Avoid out of bounds array access 2019-03-13 18:28:53 +00:00
freedreno ir3/compiler: Enable lower_io_offsets pass and handle new SSBO intrinsics 2019-03-13 21:19:44 +01:00
gallium iris: Use streaming loads to read from tiled surfaces 2019-03-13 10:54:16 -07:00
gbm gbm: drop duplicate #defines 2019-02-14 11:20:00 +00:00
getopt
glx glx: add support for GLX_ARB_create_context_no_error (v3) 2019-03-12 19:12:21 -04:00
gtest meson: hide warnings from external project gtest 2018-10-31 18:20:25 +00:00
hgl hgl/meson: drop unused include directory 2019-03-08 18:00:19 +00:00
imgui imgui: update memory editor 2019-02-26 12:49:07 +00:00
intel intel/nir: Combine store_derefs to improve code from SPIR-V 2019-03-13 08:39:16 -07:00
loader loader: use loader_open_device() to handle O_CLOEXEC 2019-02-26 11:07:23 +00:00
mapi autotools: don't build libGLES*.so with GLVND 2019-03-08 15:13:36 +00:00
mesa st/glsl_to_nir: fix incorrect arrary access 2019-03-12 14:47:21 +11:00
util util: Add a DAG datastructure. 2019-03-11 13:13:52 -07:00
vulkan wsi/x11: use WSI_FROM_HANDLE() instead of pointer casts 2019-03-11 10:49:36 +00:00
Makefile.am build: move imgui out of src/intel/tools to be reused 2019-02-21 18:06:05 +00:00
meson.build turnip: Add driver skeleton (v2) 2019-03-11 10:01:15 -07:00
SConscript scons: Remove gles option. 2018-10-19 16:50:26 +01:00