pan/mdg: Add a nir pass to reorder store_output intrinsics
authorIcecream95 <ixn@keemail.me>
Mon, 6 Jul 2020 11:52:40 +0000 (23:52 +1200)
committerMarge Bot <eric+marge@anholt.net>
Wed, 15 Jul 2020 01:30:00 +0000 (01:30 +0000)
commit0ff6263534a87534805afe6eac62ddf8ee75824b
treed2d38b931e22430b6afe70ee47e5e8523cd6976a
parent58c0e1d00564f46a8264b2ce3275920890dd8b14
pan/mdg: Add a nir pass to reorder store_output intrinsics

Real writeout stores, which break execution, need to be moved to after
dual-source stores, which are just standard register writes.

v2: Don't move stores forward, to avoid moving them to before where
    their source is written.

v3: Only reorder past dual-source stores.

Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5620>
src/panfrost/midgard/midgard_compile.c