Alyssa Rosenzweig
15257b65c6
treewide: use nir_metadata_control_flow
...
Via Coccinelle patch:
@@
@@
-nir_metadata_block_index | nir_metadata_dominance
+nir_metadata_control_flow
...plus some manual fixups for call sites missed by coccinelle.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Acked-by: Karol Herbst <kherbst@redhat.com>
Acked-by: Juan A. Suarez Romero <jasuarez@igalia.com> [broadcom]
Acked-by: Vasily Khoruzhick <anarsoul@gmail.com> [lima]
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29745 >
2024-06-17 16:28:14 -04:00
Daniel Schürmann
7af16e9f1e
nir/shader_info: remove uses_demote
...
This flag is mostly redundant with uses_discard and was only
introduced to implement demote with LLVM when it didn't have
that intrinsic.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27617 >
2024-06-17 19:37:16 +00:00
Caio Oliveira
be73fa1434
intel/elk: Remove multi-polygon support
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:19 +00:00
Caio Oliveira
fd3a815a5b
intel/elk: Remove remaining Gfx9+ code
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:19 +00:00
Caio Oliveira
9f5213923e
intel/elk: Remove Gfx9+-only passes
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
3d867e2fc7
intel/elk: Remove coarse pixel handling
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
7b651ac6c3
intel/elk: Remove Gfx9+ from compile/run functions
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
2b15a90cc3
intel/elk: Remove unused sources from ELK_SHADER_OPCODE_SEND
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
ff64e68ef4
intel/elk: Remove ex_desc and ex_mlen from elk_inst
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
a3f67c2d3a
intel/elk: Remove FB_READ opcodes
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
9b709e31cb
intel/elk: Remove Gfx12 SFIDs and related LSC code
...
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:18 +00:00
Caio Oliveira
e8c4104362
intel/elk: Remove IADD3 opcode
...
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:17 +00:00
Caio Oliveira
d1049408b5
intel/elk: Remove ROR and ROL opcodes
...
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:17 +00:00
Caio Oliveira
28a7265b10
intel/elk: Remove DP4A opcode
...
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:17 +00:00
Caio Oliveira
9e58170f84
intel/elk: Remove BTD and RT opcodes
...
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:17 +00:00
Caio Oliveira
24569b8079
intel/elk: Remove DPAS opcode
...
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:17 +00:00
Caio Oliveira
7b90470ca1
intel/elk: Remove split sends
...
They are not supported in Gfx8-.
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27629 >
2024-03-07 15:53:17 +00:00
Caio Oliveira
337641cfcc
intel/compiler: Fix SIMD lowering when instruction needs a larger SIMD
...
When lower_simd_width() encounters an instruction that needs a larger
SIMD, for example SHADER_OPCODE_TXS_LOGICAL in Gfx4 needs at least
SIMD16. In this case the builder needs to be at least as large as
max_width, otherwise the group() setup will assert.
Turns out this did not assert before "by accident", since it was
relying on the default fs_visitor builder that had a dispatch width of 64,
a bogus placeholder value, expected not to be used.
However, when we changed the code to remove that builder (and the bogus
value), we created a new builder in the pass shader dispatch_width --
which work fine except in the case where we want to "lower" the SIMD above
the shader dispatch width. The fix is to also consider the already
calculated max_width when creating the builder.
Fixes: 5b8ec015f2 ("intel/compiler: Don't use fs_visitor::bld in remaining places")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10338
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27782 >
2024-03-01 22:54:57 +00:00
Caio Oliveira
373130a66c
intel/compiler: Remove has_render_target_reads from wm_prog_data
...
This was used only by the classic i965 driver.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27772 >
2024-02-24 02:34:59 +00:00
Caio Oliveira
6648e0ebd3
intel/elk: Rename symbols
...
Either replace the BRW prefix with ELK or add an extra ELK prefix. Used
the following sed script to perform the renames in this patch:
```
# Simple prefix changes.
s/\<BRW_/ELK_/g
s/\<brw_/elk_/g
s/nir_to_brw/nir_to_elk/g
s/\<as_brw_reg\>/as_elk_reg/g
s/\<_brw_/_elk_/g
# Add prefix to various symbols.
#
# Initially I've considered using C++ namespaces here, but in various
# cases the structs or functions had to be also visible from C code.
# So added explicit prefix instead.
s/\<backend_instruction/elk_\0/g
s/\<backend_reg/elk_\0/g
s/\<backend_shader/elk_\0/g
s/\<bblock_t\>/elk_\0/g
s/\<bblock_link\>/elk_\0/g
s/\<cfg_t\>/elk_\0/g
s/\<fs_visitor\>/elk_\0/g
s/\<fs_reg\>/elk_\0/g
s/\<fs_instruction_scheduler\>/elk_\0/g
s/\<vec4_instruction_scheduler\>/elk_\0/g
s/\<instruction_scheduler\>/elk_\0/g
s/\<schedule_node\>/elk_\0/g
s/\<schedule_node_child\>/elk_\0/g
s/\<\([a-z]*_\)\?thread_payload\>/elk_\1thread_payload/g
s/\<fs_generator\>/elk_\0/g
s/\<fs_inst\>/elk_\0/g
s/\<fs_reg_alloc\>/elk_\0/g
s/\<disasm_info\>/elk_\0/g
s/\<gfx._math\>/elk_\0/g
s/\<gfx7_block_read_scratch\>/elk_\0/g
s/\<gfx6_IF\>/elk_\0/g
s/\<gfx9_fb_READ\>/elk_\0/g
s/\<gfx6_resolve_implied_move\>/elk_\0/g
# Opcodes.
s/\<opcode op\>/elk_\0/g
s/\<opcode mov_op\>/elk_\0/g
s/\<opcode opcode\>/elk_\0/g
s/enum opcode\>/enum elk_opcode/g
s/static opcode\>/static elk_opcode/g
s/\<opcode elk_op/elk_opcode elk_op/g
s/struct opcode_desc/struct elk_opcode_desc/g
s/NUM_BRW_OPCODES/NUM_ELK_OPCODES/g
s/\<.._OPCODE_/ELK_\0/g
s/\<T.._OPCODE_/ELK_\0/g
s/\<VEC4_OPCODE_/ELK_\0/g
s/\<VEC4_...\?_OPCODE_/ELK_\0/g
s/\<SHADER_OPCODE_/ELK_\0/g
# Remaining specific cases.
s/\<wm_prog_data_barycentric_modes\>/elk_\0/g
s/\<encode_slm_size\>/elk_\0/g
s/\<intel_calculate_slm_size\>/elk_\0/g
s/\<gfx6_gather_sampler_wa\>/elk_\0/g
s/\<is_3src\>/elk_\0/g
s/\<WA_/ELK_\0/g
s/\<conditional_modifier\>/elk_\0/g
s/\<pred_ctrl_align16\>/elk_\0/g
s/\<shuffle_from_32bit_read\>/elk_\0/g
s/\<shuffle_src_to_dst\>/elk_\0/g
s/\<setup_imm_..\?\>/elk_\0/g
s/\<opt_predicated_break\>/elk_\0/g
s/\<has_bank_conflict\>/elk_\0/g
s/\<dead_control_flow_eliminate\>/elk_\0/g
s/\<disasm_new_inst_group\>/elk_\0/g
s/\<disasm_initialize\>/elk_\0/g
s/\<dump_assembly\>/elk_\0/g
s/\<disasm_insert_error\>/elk_\0/g
s/\<disasm_annotate\>/elk_\0/g
s/\<enum lsc_opcode\>/enum elk_lsc_opcode/g
s/\<lsc_opcode_/elk_lsc_opcode_/g
s/\<lsc_aop_[a-z_]\+\>/elk_\0/g
s/\<type_size_vec4\>/elk_\0/g
s/\<type_size_dvec4\>/elk_\0/g
s/\<type_size_xvec4\>/elk_\0/g
s/\<type_size_[a-z4]\+_bytes\>/elk_\0/g
s/\<gfx12_systolic_depth\>/elk_\0/g
```
Acked-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27563 >
2024-02-24 00:24:31 +00:00
Caio Oliveira
f677485ad4
intel/elk: Rename C++ namespace
...
Acked-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27563 >
2024-02-24 00:24:31 +00:00
Caio Oliveira
ed89a42f7a
intel/elk: Update doxygen-like file comments
...
Not sure if we use them, but updated.
Acked-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27563 >
2024-02-24 00:24:31 +00:00
Caio Oliveira
e6022281f2
intel/elk: Rename files to use elk prefix
...
Acked-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27563 >
2024-02-24 00:24:31 +00:00