freedreno/ir3: add a pass to collect SSA uses
authorRob Clark <robdclark@chromium.org>
Thu, 12 Mar 2020 21:18:04 +0000 (14:18 -0700)
committerMarge Bot <eric+marge@anholt.net>
Sat, 4 Apr 2020 00:07:10 +0000 (00:07 +0000)
commit72f6b03aec42dcfa7b38aa4eb1c94a0143e2aed0
tree2537e2b0e03d7361f57bf1edfd6a91caa7578a4a
parent67dbe8088fd97e944ea9adbf7080d63f8343f475
freedreno/ir3: add a pass to collect SSA uses

We don't really track these as the ir is transformed, but it would be a
useful thing for some passes to have.  So add a pass to collect this
information.  It uses instr->data (generic per-pass ptr), with the
hashsets hanging under a mem_ctx for easy disposal at the end of the
pass.

Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4423>
src/freedreno/ir3/ir3.c
src/freedreno/ir3/ir3.h