panfrost/midgard: Broadcast swizzle
authorAlyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Wed, 19 Jun 2019 14:23:27 +0000 (07:23 -0700)
committerTomeu Vizoso <tomeu.vizoso@collabora.com>
Thu, 20 Jun 2019 18:52:04 +0000 (20:52 +0200)
commit195e297a92a51c9f6ad4ff75b37b8120d70e61d5
tree81bd30523f0cdccf94e6f0d7c7ee817bcbe0db0f
parent31de802e7e6428b1b84b42ff555cdb8f87a59a6e
panfrost/midgard: Broadcast swizzle

Fixes regression in shaders using ball/etc by explicitly passing through
the number of channels in the NIR op and broadcasting the last
components of the channel appropriately, as the Midgard ops are all vec4
implicitly but NIR can be vec2/3.

v2: Don't also regress every other swizzle in Equestria.

v3: Don't regress the swizzles at Canterlot High either.

Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Acked-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
src/gallium/drivers/panfrost/midgard/midgard_compile.c