mesa/src/microsoft/compiler
Jesse Natalie f9b0382faf microsoft/compiler: Emit const accesses as load_deref
There's a few changes in here that are very inter-related.

First, we stop lowering load_deref on shader_temp to load_ptr_dxil,
and just leave it as load_deref. In order for that to work, we need
the derefs to be in a shape that's acceptable to DXIL, so the only
current producer of shader_temp loads (the CLC frontend) needs to
run some lowering passes on them first.

The DXIL backend is augmented to just write out deref indices while
walking a deref chain, which will get combined in the load op into
a GEP instruction. For non-mesh/raytracing shaders, these are required
to be single-level scalar arrays, but the complexity here is preparation
for when we don't need to do that anymore.

Additionally, the const lookups are changed from using a hash table
to just putting an index on the variable.

All of this together is enough to enable the authored-forever-ago test
which uses indirect array access into a const packed struct. The
load_ptr_dxil handling didn't deal with packed structs / unaligned
accesses, but now that we're in a logical address space with derefs
instead of physical, there's no alignment to deal with anymore and
the fact that it's packed goes out the window.

This removes one custom DXIL intrinsic.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23173>
2023-06-13 00:43:36 +00:00
..
dxcapi.h dxil: Fixes compiling dxcapi.h with mingw. 2022-06-15 11:38:24 +00:00
dxil_buffer.c
dxil_buffer.h d3d12: Fix GCC warnings for missing function prototypes 2020-12-01 17:10:47 +00:00
dxil_buffer_test.c
dxil_container.c microsoft/compiler: Allocate space for I/O and viewID dependency tables before instruction processing 2023-05-10 21:42:34 +00:00
dxil_container.h microsoft/compiler: Support DXIL validator 1.7 2022-07-23 14:48:17 +00:00
dxil_dump.c microsoft/compiler: Handle struct consts in DXIL module dumper 2023-02-11 06:12:23 +00:00
dxil_dump.h
dxil_dump_decls.h microsoft/compiler: Misc fixes caught by GCC 2020-12-01 17:10:47 +00:00
dxil_enums.c compiler: Rename shader_prim to mesa_prim and replace all usage of pipe_prim_type with mesa_prim 2023-06-03 03:29:03 +00:00
dxil_enums.h microsoft/compiler: Refactor type -> resource kind helper 2023-03-23 21:48:43 +00:00
dxil_function.c microsoft/compiler: Enable packed dot product intrinsics for SM6.4+ 2023-05-11 21:56:31 +00:00
dxil_function.h microsoft/compiler: Implement more wave/quad ops 2023-01-24 11:00:05 -08:00
dxil_internal.h microsoft/compiler: Support vec/struct const vals 2023-06-13 00:43:36 +00:00
dxil_module.c microsoft/compiler: Support vec/struct const vals 2023-06-13 00:43:36 +00:00
dxil_module.h microsoft/compiler: Support vec/struct const vals 2023-06-13 00:43:36 +00:00
dxil_nir.c microsoft/compiler: Emit const accesses as load_deref 2023-06-13 00:43:36 +00:00
dxil_nir.h microsoft/compiler: Add some more lowering passes for derefs 2023-06-13 00:43:36 +00:00
dxil_nir_algebraic.py microsoft/compiler: Enable packed dot product intrinsics for SM6.4+ 2023-05-11 21:56:31 +00:00
dxil_nir_lower_int_cubemaps.c treewide: Use nir_trim_vector more 2023-06-06 18:52:25 +00:00
dxil_nir_lower_int_cubemaps.h microsoft/compiler: make sampler-lowering optional 2022-06-10 22:14:14 +00:00
dxil_nir_lower_int_samplers.c treewide: Use nir_trim_vector more 2023-06-06 18:52:25 +00:00
dxil_nir_lower_int_samplers.h d3d12: Don't clear d3d12_shader_key 2023-02-13 22:57:03 +00:00
dxil_nir_lower_vs_vertex_conversion.c microsoft/compiler: Add support for more scaled formats 2022-06-14 17:42:51 +00:00
dxil_nir_tess.c nir: use generated immediate comparison helpers 2023-06-05 13:40:08 +00:00
dxil_signature.c microsoft/compiler: Fix usage of type var in semantic asserts 2023-06-01 23:39:41 +00:00
dxil_signature.h microsoft/compiler: DXIL validator 1.6 uses a new PSV struct version 2022-07-23 14:48:17 +00:00
dxil_validator.cpp Add checks for NULL dxil_validator 2023-05-17 15:33:17 +00:00
dxil_validator.h microsoft/spirv2dxil: Refactor to make SM and validator versions public 2022-10-24 16:15:31 +00:00
dxil_versions.h microsoft/spirv2dxil: Refactor to make SM and validator versions public 2022-10-24 16:15:31 +00:00
meson.build meson: add dep_valgrind dependency for 'dxil_compiler' 2022-10-20 01:32:47 +00:00
nir_to_dxil.c microsoft/compiler: Emit const accesses as load_deref 2023-06-13 00:43:36 +00:00
nir_to_dxil.h microsoft/compiler: Take inputs from callers before providing nir options 2023-05-11 21:56:31 +00:00