pan/mdg: Precompute mir_special_index
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Wed, 6 May 2020 20:06:54 +0000 (16:06 -0400)
committerMarge Bot <eric+marge@anholt.net>
Wed, 20 May 2020 17:06:34 +0000 (17:06 +0000)
commitc24dfc9da42abadf079b012f0d6e52fb4c829112
tree7fdc820fb2bc87037fe9501284c6ad1898dbba90
parent4cf02b5d4a649b9fe621e3ef855021389663222d
pan/mdg: Precompute mir_special_index

Rather than O(N) each call, we can precompute the whole set - also O(N)
- and then subsequent checks are O(1).

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5123>
src/panfrost/midgard/compiler.h
src/panfrost/midgard/mir.c
src/panfrost/midgard/mir_promote_uniforms.c