mesa/src/panfrost
Alyssa Rosenzweig c39896b17b nir: Use getters for nir_src::parent_*
First, we need to give the parent_instr field a unique name to be able to
replace with a helper.  We have parent_instr fields for both nir_src and
nir_def, so let's rename nir_src::parent_instr in preparation for rework.

This was done with a combination of sed and manual fix-ups.

Then we use semantic patches plus manual fixups:

    @@
    expression s;
    @@

    -s->renamed_parent_instr
    +nir_src_parent_instr(s)

    @@
    expression s;
    @@

    -s.renamed_parent_instr
    +nir_src_parent_instr(&s)

    @@
    expression s;
    @@

    -s->parent_if
    +nir_src_parent_if(s)

    @@
    expression s;
    @@

    -s.renamed_parent_if
    +nir_src_parent_if(&s)

    @@
    expression s;
    @@

    -s->is_if
    +nir_src_is_if(s)

    @@
    expression s;
    @@

    -s.is_if
    +nir_src_is_if(&s)

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com>
Acked-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24671>
2023-10-10 04:58:05 -04:00
..
ci ci: Disable known broken Bifrost Vulkan job 2023-09-02 13:32:17 +00:00
compiler treewide: Drop nir_ssa_for_src users 2023-09-18 10:25:17 -04:00
drm-shim panfrost: clang-format the tree 2022-12-24 02:22:57 +00:00
ds panfrost: rename *.cc files to *.cpp 2023-05-26 18:07:38 +01:00
include panfrost: prepare pan_image_view for multiplanar formats 2023-08-07 19:35:12 +00:00
lib panfrost: Add GPU variant of G57 to the set of known ids 2023-10-04 16:32:05 +00:00
midgard nir: Use getters for nir_src::parent_* 2023-10-10 04:58:05 -04:00
perf panfrost: clang-format the tree 2022-12-24 02:22:57 +00:00
shared meson: inline gtest_test_protocol now that it's always 'gtest' 2023-03-10 07:20:29 +00:00
tools pan/decode: handle more than one panfrost_device 2023-08-14 22:41:10 +00:00
util treewide: Drop nir_ssa_for_src users 2023-09-18 10:25:17 -04:00
vulkan meson: Remove unnecessary inc_compiler mentions 2023-09-22 14:52:50 +00:00
.clang-format clang-format: Disable formatting by default 2023-08-13 16:48:49 +02:00
meson.build panfrost: drop no-longer-needed libglsl 2023-02-10 14:09:37 +00:00