Mesa (main): pan/bi: Lower swizzles on MUX.v2i16
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Feb 19 03:33:22 UTC 2022
Module: Mesa
Branch: main
Commit: 62533a6e643a1531ae19ec4a6bc5b615ce2a6820
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=62533a6e643a1531ae19ec4a6bc5b615ce2a6820
Author: Alyssa Rosenzweig <alyssa at collabora.com>
Date: Wed Jan 5 17:39:07 2022 -0500
pan/bi: Lower swizzles on MUX.v2i16
We'll generate this in a moment.
Signed-off-by: Alyssa Rosenzweig <alyssa at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14576>
---
src/panfrost/bifrost/bi_lower_swizzle.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/panfrost/bifrost/bi_lower_swizzle.c b/src/panfrost/bifrost/bi_lower_swizzle.c
index b7549b0f385..ddb8d1854cd 100644
--- a/src/panfrost/bifrost/bi_lower_swizzle.c
+++ b/src/panfrost/bifrost/bi_lower_swizzle.c
@@ -84,6 +84,13 @@ bi_lower_swizzle_16(bi_context *ctx, bi_instr *ins, unsigned src)
else
break;
+ /* For some reason MUX.v2i16 allows swaps but not replication */
+ case BI_OPCODE_MUX_V2I16:
+ if (ins->src[src].swizzle == BI_SWIZZLE_H10)
+ return;
+ else
+ break;
+
/* We don't want to deal with reswizzling logic in modifier prop. Move
* the swizzle outside, it's easier for clamp propagation. */
case BI_OPCODE_FCLAMP_V2F16:
More information about the mesa-commit
mailing list